From 68043da40b396becbd3f644b1013470926ba1340 Mon Sep 17 00:00:00 2001 From: aguspe Date: Sat, 3 Aug 2024 20:41:46 +0200 Subject: [PATCH 1/2] Add examples for documentation --- .../ruby/spec/interactions/browser_spec.rb | 31 +++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 examples/ruby/spec/interactions/browser_spec.rb diff --git a/examples/ruby/spec/interactions/browser_spec.rb b/examples/ruby/spec/interactions/browser_spec.rb new file mode 100644 index 000000000000..14b622f178dc --- /dev/null +++ b/examples/ruby/spec/interactions/browser_spec.rb @@ -0,0 +1,31 @@ +require 'spec_helper' + +RSpec.describe 'Browser' do + let(:driver) { start_session } + + it 'navigates to a page' do + driver.navigate.to 'https://www.selenium.dev/' + expect(driver.current_url).to eq 'https://www.selenium.dev/' + end + + it 'navigates back' do + driver.navigate.to 'https://www.selenium.dev/' + driver.navigate.to 'https://www.selenium.dev/selenium/web/inputs.html' + driver.navigate.back + expect(driver.current_url).to eq 'https://www.selenium.dev/' + end + + it 'navigates forward' do + driver.navigate.to 'https://www.selenium.dev/' + driver.navigate.to 'https://www.selenium.dev/selenium/web/inputs.html' + driver.navigate.back + driver.navigate.forward + expect(driver.current_url).to eq 'https://www.selenium.dev/selenium/web/inputs.html' + end + + it 'refreshes the page' do + driver.navigate.to 'https://www.selenium.dev/' + driver.navigate.refresh + expect(driver.current_url).to eq 'https://www.selenium.dev/' + end +end From 2ec2cb9fb70371463edb32346942777243d3e619 Mon Sep 17 00:00:00 2001 From: aguspe Date: Sun, 4 Aug 2024 13:25:56 +0200 Subject: [PATCH 2/2] Move documentation examples --- .../ruby/spec/interactions/browser_spec.rb | 26 ++++------------ .../ruby/spec/interactions/navigation_spec.rb | 31 +++++++++++++++++-- .../webdriver/interactions/_index.en.md | 12 ++++--- .../webdriver/interactions/_index.ja.md | 8 +++-- .../webdriver/interactions/_index.pt-br.md | 8 +++-- .../webdriver/interactions/_index.zh-cn.md | 8 +++-- .../webdriver/interactions/navigation.en.md | 18 +++++++---- .../webdriver/interactions/navigation.ja.md | 22 +++++++------ .../interactions/navigation.pt-br.md | 22 +++++++------ .../interactions/navigation.zh-cn.md | 20 ++++++------ 10 files changed, 107 insertions(+), 68 deletions(-) diff --git a/examples/ruby/spec/interactions/browser_spec.rb b/examples/ruby/spec/interactions/browser_spec.rb index 14b622f178dc..8bc281c163aa 100644 --- a/examples/ruby/spec/interactions/browser_spec.rb +++ b/examples/ruby/spec/interactions/browser_spec.rb @@ -3,29 +3,15 @@ RSpec.describe 'Browser' do let(:driver) { start_session } - it 'navigates to a page' do + it 'gets the current title' do driver.navigate.to 'https://www.selenium.dev/' - expect(driver.current_url).to eq 'https://www.selenium.dev/' + current_title = driver.title + expect(current_title).to eq 'Selenium' end - it 'navigates back' do + it 'gets the current url' do driver.navigate.to 'https://www.selenium.dev/' - driver.navigate.to 'https://www.selenium.dev/selenium/web/inputs.html' - driver.navigate.back - expect(driver.current_url).to eq 'https://www.selenium.dev/' - end - - it 'navigates forward' do - driver.navigate.to 'https://www.selenium.dev/' - driver.navigate.to 'https://www.selenium.dev/selenium/web/inputs.html' - driver.navigate.back - driver.navigate.forward - expect(driver.current_url).to eq 'https://www.selenium.dev/selenium/web/inputs.html' - end - - it 'refreshes the page' do - driver.navigate.to 'https://www.selenium.dev/' - driver.navigate.refresh - expect(driver.current_url).to eq 'https://www.selenium.dev/' + current_url = driver.current_url + expect(current_url).to eq 'https://www.selenium.dev/' end end diff --git a/examples/ruby/spec/interactions/navigation_spec.rb b/examples/ruby/spec/interactions/navigation_spec.rb index d4a16a415b52..36c60e4ace26 100644 --- a/examples/ruby/spec/interactions/navigation_spec.rb +++ b/examples/ruby/spec/interactions/navigation_spec.rb @@ -1,7 +1,32 @@ -# frozen_string_literal: true - require 'spec_helper' -RSpec.describe 'Navigation' do +RSpec.describe 'Browser' do let(:driver) { start_session } + + it 'navigates to a page' do + driver.navigate.to 'https://www.selenium.dev/' + driver.get 'https://www.selenium.dev/' + expect(driver.current_url).to eq 'https://www.selenium.dev/' + end + + it 'navigates back' do + driver.navigate.to 'https://www.selenium.dev/' + driver.navigate.to 'https://www.selenium.dev/selenium/web/inputs.html' + driver.navigate.back + expect(driver.current_url).to eq 'https://www.selenium.dev/' + end + + it 'navigates forward' do + driver.navigate.to 'https://www.selenium.dev/' + driver.navigate.to 'https://www.selenium.dev/selenium/web/inputs.html' + driver.navigate.back + driver.navigate.forward + expect(driver.current_url).to eq 'https://www.selenium.dev/selenium/web/inputs.html' + end + + it 'refreshes the page' do + driver.navigate.to 'https://www.selenium.dev/' + driver.navigate.refresh + expect(driver.current_url).to eq 'https://www.selenium.dev/' + end end diff --git a/website_and_docs/content/documentation/webdriver/interactions/_index.en.md b/website_and_docs/content/documentation/webdriver/interactions/_index.en.md index b02938a67daa..7cf5224f2c1b 100644 --- a/website_and_docs/content/documentation/webdriver/interactions/_index.en.md +++ b/website_and_docs/content/documentation/webdriver/interactions/_index.en.md @@ -23,12 +23,14 @@ You can read the current page title from the browser: {{< tab header="Python" text=true >}} {{< gh-codeblock path="examples/python/tests/interactions/test_interactions.py#L7" >}} {{< /tab >}} - {{< tab header="CSharp" >}}driver.Title;{{< /tab >}} - {{< tab header="Ruby" >}}driver.title{{< /tab >}} +{{< tab header="CSharp" >}}driver.Title;{{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/browser_spec.rb#L8" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/interactionsIndex.spec.js#L20" >}} {{< /tab >}} - {{< tab header="Kotlin" >}}driver.title{{< /tab >}} +{{< tab header="Kotlin" >}}driver.title{{< /tab >}} {{< /tabpane >}} @@ -45,7 +47,9 @@ You can read the current URL from the browser's address bar using: {{< gh-codeblock path="examples/python/tests/interactions/test_interactions.py#L10" >}} {{< /tab >}} {{< tab header="CSharp" >}}driver.Url;{{< /tab >}} -{{< tab header="Ruby" >}}driver.current_url{{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/browser_spec.rb#L14" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/interactionsIndex.spec.js#L24" >}} {{< /tab >}} diff --git a/website_and_docs/content/documentation/webdriver/interactions/_index.ja.md b/website_and_docs/content/documentation/webdriver/interactions/_index.ja.md index c416bd2fe47e..8bf9e9d0908b 100644 --- a/website_and_docs/content/documentation/webdriver/interactions/_index.ja.md +++ b/website_and_docs/content/documentation/webdriver/interactions/_index.ja.md @@ -23,7 +23,9 @@ aliases: [ {{< gh-codeblock path="examples/python/tests/interactions/test_interactions.py#L7" >}} {{< /tab >}} {{< tab header="CSharp" >}}driver.Title;{{< /tab >}} - {{< tab header="Ruby" >}}driver.title{{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/browser_spec.rb#L8" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/interactionsIndex.spec.js#L20" >}} {{< /tab >}} @@ -43,7 +45,9 @@ aliases: [ {{< gh-codeblock path="examples/python/tests/interactions/test_interactions.py#L10" >}} {{< /tab >}} {{< tab header="CSharp" >}}driver.Url;{{< /tab >}} -{{< tab header="Ruby" >}}driver.current_url{{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/browser_spec.rb#L14" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/interactionsIndex.spec.js#L24" >}} {{< /tab >}} diff --git a/website_and_docs/content/documentation/webdriver/interactions/_index.pt-br.md b/website_and_docs/content/documentation/webdriver/interactions/_index.pt-br.md index 151a234e12e7..a62f0eb7dd37 100644 --- a/website_and_docs/content/documentation/webdriver/interactions/_index.pt-br.md +++ b/website_and_docs/content/documentation/webdriver/interactions/_index.pt-br.md @@ -24,7 +24,9 @@ Você pode ler o título da página atual no navegador: {{< gh-codeblock path="examples/python/tests/interactions/test_interactions.py#L7" >}} {{< /tab >}} {{< tab header="CSharp" >}}driver.Title;{{< /tab >}} - {{< tab header="Ruby" >}}driver.title{{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/browser_spec.rb#L8" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/interactionsIndex.spec.js#L20" >}} {{< /tab >}} @@ -44,7 +46,9 @@ Você pode ler a URL atual na barra de endereço do navegador usando: {{< gh-codeblock path="examples/python/tests/interactions/test_interactions.py#L10" >}} {{< /tab >}} {{< tab header="CSharp" >}}driver.Url;{{< /tab >}} -{{< tab header="Ruby" >}}driver.current_url{{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/browser_spec.rb#L14" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/interactionsIndex.spec.js#L24" >}} {{< /tab >}} diff --git a/website_and_docs/content/documentation/webdriver/interactions/_index.zh-cn.md b/website_and_docs/content/documentation/webdriver/interactions/_index.zh-cn.md index a974f9f118ec..6e2866f8d0a7 100644 --- a/website_and_docs/content/documentation/webdriver/interactions/_index.zh-cn.md +++ b/website_and_docs/content/documentation/webdriver/interactions/_index.zh-cn.md @@ -23,7 +23,9 @@ aliases: [ {{< gh-codeblock path="examples/python/tests/interactions/test_interactions.py#L7" >}} {{< /tab >}} {{< tab header="CSharp" >}}driver.Title;{{< /tab >}} -{{< tab header="Ruby" >}}driver.title{{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/browser_spec.rb#L8" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/interactionsIndex.spec.js#L20" >}} {{< /tab >}} @@ -42,7 +44,9 @@ aliases: [ {{< gh-codeblock path="examples/python/tests/interactions/test_interactions.py#L10" >}} {{< /tab >}} {{< tab header="CSharp" >}}driver.Url;{{< /tab >}} -{{< tab header="Ruby" >}}driver.current_url{{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/browser_spec.rb#L14" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/interactionsIndex.spec.js#L24" >}} {{< /tab >}} diff --git a/website_and_docs/content/documentation/webdriver/interactions/navigation.en.md b/website_and_docs/content/documentation/webdriver/interactions/navigation.en.md index 9ba0aadbebfc..14633cc9afe2 100644 --- a/website_and_docs/content/documentation/webdriver/interactions/navigation.en.md +++ b/website_and_docs/content/documentation/webdriver/interactions/navigation.en.md @@ -23,9 +23,9 @@ open your website. This can be achieved in a single line: {{< tab header="CSharp" text=true >}} {{< gh-codeblock path="examples/dotnet/SeleniumDocs/Interactions/NavigationTest.cs#L17-L20" >}} {{< /tab >}} - {{< tab header="Ruby" >}} -driver.navigate.to 'https://selenium.dev' - {{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/navigation_spec.rb#L7-L9" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/navigation.spec.js#L16-L20" >}} {{< /tab >}} @@ -53,7 +53,9 @@ Pressing the browser's back button: {{< tab header="CSharp" text=true >}} {{< gh-codeblock path="examples/dotnet/SeleniumDocs/Interactions/NavigationTest.cs#L24-L25" >}} {{< /tab >}} - {{< tab header="Ruby" >}}driver.navigate.back{{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/navigation_spec.rb#L15" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/navigation.spec.js#L24-L25" >}} {{< /tab >}} @@ -73,7 +75,9 @@ Pressing the browser's forward button: {{< tab header="CSharp" text=true >}} {{< gh-codeblock path="examples/dotnet/SeleniumDocs/Interactions/NavigationTest.cs#L29-L30" >}} {{< /tab >}} - {{< tab header="Ruby" >}}driver.navigate.forward{{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/navigation_spec.rb#L23" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/navigation.spec.js#L29-L30" >}} {{< /tab >}} @@ -94,7 +98,9 @@ Refresh the current page: {{< tab header="CSharp" text=true >}} {{< gh-codeblock path="examples/dotnet/SeleniumDocs/Interactions/NavigationTest.cs#L34-L35" >}} {{< /tab >}} - {{< tab header="Ruby" >}}driver.navigate.refresh{{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/navigation_spec.rb#L29" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/navigation.spec.js#L34-L35" >}} {{< /tab >}} diff --git a/website_and_docs/content/documentation/webdriver/interactions/navigation.ja.md b/website_and_docs/content/documentation/webdriver/interactions/navigation.ja.md index b9936ca9cab4..97c16a0c042e 100644 --- a/website_and_docs/content/documentation/webdriver/interactions/navigation.ja.md +++ b/website_and_docs/content/documentation/webdriver/interactions/navigation.ja.md @@ -22,13 +22,9 @@ aliases: [ {{< tab header="CSharp" text=true >}} {{< gh-codeblock path="examples/dotnet/SeleniumDocs/Interactions/NavigationTest.cs#L17-L20" >}} {{< /tab >}} - {{< tab header="Ruby" >}} - # Convenient way -driver.get 'https://selenium.dev' - - # Longer Way -driver.navigate.to 'https://selenium.dev' - {{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/navigation_spec.rb#L7-L9" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/navigation.spec.js#L16-L20" >}} {{< /tab >}} @@ -54,7 +50,9 @@ driver.navigate().to("https://selenium.dev") {{< tab header="CSharp" text=true >}} {{< gh-codeblock path="examples/dotnet/SeleniumDocs/Interactions/NavigationTest.cs#L24-L25" >}} {{< /tab >}} - {{< tab header="Ruby" >}}driver.navigate.back{{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/navigation_spec.rb#L15" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/navigation.spec.js#L24-L25" >}} {{< /tab >}} @@ -76,7 +74,9 @@ driver.navigate().to("https://selenium.dev") {{< tab header="CSharp" text=true >}} {{< gh-codeblock path="examples/dotnet/SeleniumDocs/Interactions/NavigationTest.cs#L29-L30" >}} {{< /tab >}} - {{< tab header="Ruby" >}}driver.navigate.forward{{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/navigation_spec.rb#L23" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/navigation.spec.js#L29-L30" >}} {{< /tab >}} @@ -98,7 +98,9 @@ driver.navigate().to("https://selenium.dev") {{< tab header="CSharp" text=true >}} {{< gh-codeblock path="examples/dotnet/SeleniumDocs/Interactions/NavigationTest.cs#L34-L35" >}} {{< /tab >}} - {{< tab header="Ruby" >}}driver.navigate.refresh{{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/navigation_spec.rb#L29" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/navigation.spec.js#L34-L35" >}} {{< /tab >}} diff --git a/website_and_docs/content/documentation/webdriver/interactions/navigation.pt-br.md b/website_and_docs/content/documentation/webdriver/interactions/navigation.pt-br.md index f4c66ae225d1..274d5cee2b21 100644 --- a/website_and_docs/content/documentation/webdriver/interactions/navigation.pt-br.md +++ b/website_and_docs/content/documentation/webdriver/interactions/navigation.pt-br.md @@ -23,13 +23,9 @@ abrir o seu site. Isso pode ser feito em uma única linha, utilize o seguinte co {{< tab header="CSharp" text=true >}} {{< gh-codeblock path="examples/dotnet/SeleniumDocs/Interactions/NavigationTest.cs#L17-L20" >}} {{< /tab >}} - {{< tab header="Ruby" >}} - # Convenient way -driver.get 'https://selenium.dev' - - # Longer Way -driver.navigate.to 'https://selenium.dev' - {{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/navigation_spec.rb#L7-L9" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/navigation.spec.js#L16-L20" >}} {{< /tab >}} @@ -55,7 +51,9 @@ Pressionando o botão Voltar do navegador: {{< tab header="CSharp" text=true >}} {{< gh-codeblock path="examples/dotnet/SeleniumDocs/Interactions/NavigationTest.cs#L24-L25" >}} {{< /tab >}} - {{< tab header="Ruby" >}}driver.navigate.back{{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/navigation_spec.rb#L15" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/navigation.spec.js#L24-L25" >}} {{< /tab >}} @@ -75,7 +73,9 @@ Pressionando o botão Avançar do navegador: {{< tab header="CSharp" text=true >}} {{< gh-codeblock path="examples/dotnet/SeleniumDocs/Interactions/NavigationTest.cs#L29-L30" >}} {{< /tab >}} - {{< tab header="Ruby" >}}driver.navigate.forward{{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/navigation_spec.rb#L23" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/navigation.spec.js#L29-L30" >}} {{< /tab >}} @@ -96,7 +96,9 @@ Atualizando a página atual: {{< tab header="CSharp" text=true >}} {{< gh-codeblock path="examples/dotnet/SeleniumDocs/Interactions/NavigationTest.cs#L34-L35" >}} {{< /tab >}} - {{< tab header="Ruby" >}}driver.navigate.refresh{{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/navigation_spec.rb#L29" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/navigation.spec.js#L34-L35" >}} {{< /tab >}} diff --git a/website_and_docs/content/documentation/webdriver/interactions/navigation.zh-cn.md b/website_and_docs/content/documentation/webdriver/interactions/navigation.zh-cn.md index 7e7c750a1e89..a1470a1b6669 100644 --- a/website_and_docs/content/documentation/webdriver/interactions/navigation.zh-cn.md +++ b/website_and_docs/content/documentation/webdriver/interactions/navigation.zh-cn.md @@ -22,12 +22,8 @@ aliases: [ {{< tab header="CSharp" text=true >}} {{< gh-codeblock path="examples/dotnet/SeleniumDocs/Interactions/NavigationTest.cs#L17-L20" >}} {{< /tab >}} -{{< tab header="Ruby" >}} - # 简便的方法 -driver.get 'https://selenium.dev' - - # 更长的方法 -driver.navigate.to 'https://selenium.dev' +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/navigation_spec.rb#L7-L9" >}} {{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/navigation.spec.js#L16-L20" >}} @@ -54,7 +50,9 @@ driver.navigate().to("https://selenium.dev") {{< tab header="CSharp" text=true >}} {{< gh-codeblock path="examples/dotnet/SeleniumDocs/Interactions/NavigationTest.cs#L24-L25" >}} {{< /tab >}} -{{< tab header="Ruby" >}}driver.navigate.back{{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/navigation_spec.rb#L15" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/navigation.spec.js#L24-L25" >}} {{< /tab >}} @@ -74,7 +72,9 @@ driver.navigate().to("https://selenium.dev") {{< tab header="CSharp" text=true >}} {{< gh-codeblock path="examples/dotnet/SeleniumDocs/Interactions/NavigationTest.cs#L29-L30" >}} {{< /tab >}} -{{< tab header="Ruby" >}}driver.navigate.forward{{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/navigation_spec.rb#L23" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/navigation.spec.js#L29-L30" >}} {{< /tab >}} @@ -94,7 +94,9 @@ driver.navigate().to("https://selenium.dev") {{< tab header="CSharp" text=true >}} {{< gh-codeblock path="examples/dotnet/SeleniumDocs/Interactions/NavigationTest.cs#L34-L35" >}} {{< /tab >}} -{{< tab header="Ruby" >}}driver.navigate.refresh{{< /tab >}} +{{< tab header="Ruby" text=true >}} +{{< gh-codeblock path="examples/ruby/spec/interactions/navigation_spec.rb#L29" >}} +{{< /tab >}} {{< tab header="JavaScript" text=true >}} {{< gh-codeblock path="examples/javascript/test/interactions/navigation.spec.js#L34-L35" >}} {{< /tab >}}