Skip to content

Commit

Permalink
fix browser name and version tags for cuprite
Browse files Browse the repository at this point in the history
  • Loading branch information
anmarchenko committed Jan 21, 2025
1 parent b44f9a9 commit 3499c33
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
4 changes: 2 additions & 2 deletions lib/datadog/ci/contrib/cuprite/driver.rb
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@ def visit(url)
# set the tags specific to the browser test
active_test.set_tag(CI::Ext::Test::TAG_BROWSER_DRIVER, "cuprite")
active_test.set_tag(CI::Ext::Test::TAG_BROWSER_DRIVER_VERSION, datadog_integration.version)
active_test.set_tag(CI::Ext::Test::TAG_BROWSER_NAME, browser.options.browser_name)
active_test.set_tag(CI::Ext::Test::TAG_BROWSER_VERSION, browser.version)
active_test.set_tag(CI::Ext::Test::TAG_BROWSER_NAME, browser.options.browser_name || "chrome")
active_test.set_tag(CI::Ext::Test::TAG_BROWSER_VERSION, browser.version.product)

result
end
Expand Down
6 changes: 5 additions & 1 deletion vendor/rbs/cuprite/0/driver.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ module Ferrum
end

class Ferrum::Browser
def version: () -> String
def version: () -> Ferrum::Browser::VersionInfo

def options: () -> Ferrum::Browser::Options
end
Expand All @@ -17,6 +17,10 @@ class Ferrum::Browser::Options
def browser_name: () -> String
end

class Ferrum::Browser::VersionInfo
def product: () -> String
end

module Capybara::Cuprite::Driver
def visit: (String url) -> untyped

Expand Down

0 comments on commit 3499c33

Please sign in to comment.