Skip to content

Commit b8c1c5f

Browse files
yuriverweijCopilot
andcommitted
Add SKIP_ON_WINDOWS tag to relevant test cases and update run.py to exclude Windows tests
Co-authored-by: Copilot <copilot@github.com>
1 parent da2f1b8 commit b8c1c5f

8 files changed

Lines changed: 23 additions & 10 deletions

File tree

atest/acceptance/2-event_firing_webdriver/event_firing_webdriver.robot

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ ${event_firing_or_none} ${NONE}
1010

1111
*** Test Cases ***
1212
Open Browser To Start Page
13-
[Tags] NoGrid
13+
[Tags] NoGrid SKIP_ON_WINDOWS
1414
[Documentation]
1515
... LOG 1:30 DEBUG Wrapping driver to event_firing_webdriver.
1616
... LOG 1:32 INFO Got driver also from SeleniumLibrary.

atest/acceptance/create_webdriver.robot

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ Create Webdriver Creates Functioning WebDriver
88
[Documentation]
99
... LOG 1:1 INFO REGEXP: Creating an instance of the \\w+ WebDriver.
1010
... LOG 1:18 DEBUG REGEXP: Created \\w+ WebDriver instance with session id (\\w|-)+.
11-
[Tags] Known Issue Internet Explorer Known Issue Safari
11+
[Tags] Known Issue Internet Explorer Known Issue Safari SKIP_ON_WINDOWS
1212
[Setup] Set Driver Variables
1313
Create Webdriver ${DRIVER_NAME} kwargs=${KWARGS}
1414
Go To ${FRONT_PAGE}

atest/acceptance/entry_point.robot

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ Entry Point Version
77
${process} = Run Process
88
... python -m SeleniumLibrary.entry --version
99
... shell=True
10-
... cwd=${EXECDIR}/src
10+
... cwd=${EXECDIR}${/}src
1111
Log ${process.stdout}
1212
Log ${process.stderr}
1313
Should Be Equal As Integers ${process.rc} 0
@@ -17,18 +17,18 @@ Entry Point Version
1717

1818
Entry Point Translation
1919
${process} = Run Process
20-
... python -m SeleniumLibrary.entry translation ${OUTPUT_DIR}/translation.json
20+
... python -m SeleniumLibrary.entry translation ${OUTPUT_DIR}${/}translation.json
2121
... shell=True
22-
... cwd=${EXECDIR}/src
22+
... cwd=${EXECDIR}${/}src
2323
Log ${process.stdout}
2424
Log ${process.stderr}
2525
Should Be Equal As Integers ${process.rc} 0
2626
Should Be Empty ${process.stderr}
27-
Should Be Equal ${process.stdout} Translation file created in ${OUTPUT_DIR}/translation.json
27+
Should Be Equal ${process.stdout} Translation file created in ${OUTPUT_DIR}${/}translation.json
2828
${process} = Run Process
29-
... python -m SeleniumLibrary.entry translation --compare ${OUTPUT_DIR}/translation.json
29+
... python -m SeleniumLibrary.entry translation --compare ${OUTPUT_DIR}${/}translation.json
3030
... shell=True
31-
... cwd=${EXECDIR}/src
31+
... cwd=${EXECDIR}${/}src
3232
Log ${process.stdout}
3333
Log ${process.stderr}
3434
Should Be Equal As Integers ${process.rc} 0

atest/acceptance/keywords/page_load_timeout.robot

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ Test Teardown Close Browser And Reset Page Load Timeout
66

77
*** Test Cases ***
88
Should Open Browser With Default Page Load Timeout
9+
[Tags] SKIP_ON_WINDOWS
910
[Documentation] Verify that 'Open Browser' changes the page load timeout.
1011
... LOG 1.1.1:26 DEBUG REGEXP: POST http://localhost:\\d{2,5}/session/[a-f0-9-]+/timeouts {['\\\"]pageLoad['\\\"]: 300000}
1112
... LOG 1.1.1:28 DEBUG STARTS: Remote response: status=200

atest/acceptance/multiple_browsers_options.robot

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,15 @@ Documentation Creating test which would work on all browser is not possible.
88
99
*** Test Cases ***
1010
Chrome Browser With Selenium Options As String
11+
[Tags] SKIP_ON_WINDOWS
1112
[Documentation]
1213
... LOG 1:13 DEBUG REGEXP: .*['\\\"]goog:chromeOptions['\\\"].*
1314
... LOG 1:13 DEBUG REGEXP: .*args['\\\"]: \\\[['\\\"]--disable-dev-shm-usage['\\\"].*
1415
Open Browser ${FRONT PAGE} ${BROWSER} remote_url=${REMOTE_URL}
1516
... desired_capabilities=${DESIRED_CAPABILITIES} options=add_argument("--disable-dev-shm-usage")
1617

1718
Chrome Browser With Selenium Options As String With Attribute As True
19+
[Tags] SKIP_ON_WINDOWS
1820
[Documentation]
1921
... LOG 1:13 DEBUG REGEXP: .*['\\\"]goog:chromeOptions['\\\"].*
2022
... LOG 1:13 DEBUG REGEXP: .*args['\\\"]: \\\[['\\\"]--disable-dev-shm-usage['\\\"].*
@@ -23,7 +25,7 @@ Chrome Browser With Selenium Options As String With Attribute As True
2325
... desired_capabilities=${DESIRED_CAPABILITIES} options=add_argument ( "--disable-dev-shm-usage" ) ; add_argument ( "--headless=new" )
2426

2527
Chrome Browser With Selenium Options With Complex Object
26-
[Tags] NoGrid
28+
[Tags] NoGrid SKIP_ON_WINDOWS
2729
[Documentation]
2830
... LOG 1:13 DEBUG REGEXP: .*['\\\"]goog:chromeOptions['\\\"].*
2931
... LOG 1:13 DEBUG REGEXP: .*['\\\"]mobileEmulation['\\\"]: {['\\\"]deviceName['\\\"]: ['\\\"]Galaxy S5['\\\"].*
@@ -32,6 +34,7 @@ Chrome Browser With Selenium Options With Complex Object
3234
... desired_capabilities=${DESIRED_CAPABILITIES} options=add_argument ( "--disable-dev-shm-usage" ) ; add_experimental_option( "mobileEmulation" , { 'deviceName' : 'Galaxy S5'})
3335

3436
Chrome Browser With Selenium Options Object
37+
[Tags] SKIP_ON_WINDOWS
3538
[Documentation]
3639
... LOG 2:13 DEBUG REGEXP: .*['\\\"]goog:chromeOptions['\\\"].*
3740
... LOG 2:13 DEBUG REGEXP: .*args['\\\"]: \\\[['\\\"]--disable-dev-shm-usage['\\\"].*
@@ -46,6 +49,7 @@ Chrome Browser With Selenium Options Invalid Method
4649

4750

4851
Chrome Browser With Selenium Options Argument With Semicolon
52+
[Tags] SKIP_ON_WINDOWS
4953
[Documentation]
5054
... LOG 1:13 DEBUG REGEXP: .*['\\\"]goog:chromeOptions['\\\"].*
5155
... LOG 1:13 DEBUG REGEXP: .*\\\[['\\\"]has;semicolon['\\\"].*

atest/acceptance/multiple_browsers_service.robot

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
Suite Teardown Close All Browsers
33
Library ../resources/testlibs/get_driver_path.py
44
Resource resource.robot
5+
Test Tags SKIP_ON_WINDOWS
56
# Force Tags Known Issue Firefox Known Issue Safari Known Issue Internet Explorer
67
Documentation Creating test which would work on all browser is not possible.
78
... These tests are for Chrome only.
@@ -11,18 +12,21 @@ Chrome Browser With Chrome Service As String
1112
[Documentation]
1213
... LOG 2:3 DEBUG STARTS: Started executable:
1314
... LOG 2:4 DEBUG GLOB: POST*/session*
15+
[Tags] Known Issue Firefox Known Issue Safari Known Issue Internet Explorer
1416
${driver_path}= Get Driver Path Chrome
1517
Open Browser ${FRONT PAGE} Chrome remote_url=${REMOTE_URL}
1618
... service=executable_path='${driver_path}'
1719

1820
Chrome Browser With Chrome Service As String With service_args As List
21+
[Tags] Known Issue Firefox Known Issue Safari Known Issue Internet Explorer
1922
Open Browser ${FRONT PAGE} Chrome remote_url=${REMOTE_URL}
2023
... service=service_args=['--append-log', '--readable-timestamp']; log_output='${OUTPUT_DIR}/chromedriverlog.txt'
2124
File Should Exist ${OUTPUT_DIR}/chromedriverlog.txt
2225
# ... service=service_args=['--append-log', '--readable-timestamp']; log_output='./'
2326
# ... service=service_args=['--append-log', '--readable-timestamp']
2427

2528
Firefox Browser With Firefox Service As String
29+
[Tags] Known Issue Chrome Known Issue Safari Known Issue Internet Explorer
2630
[Documentation]
2731
... LOG 2:3 DEBUG STARTS: Started executable:
2832
... LOG 2:4 DEBUG GLOB: POST*/session*

atest/acceptance/open_and_close.robot

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ Close Browser Does Nothing When No Browser Is Opened
1515
Close Browser
1616

1717
Browser Open With Not Well-Formed URL Should Close
18+
[Tags] SKIP_ON_WINDOWS
1819
[Documentation] Verify after incomplete 'Open Browser' browser closes
1920
... LOG 1.1:34 DEBUG STARTS: Opened browser with session id
2021
... LOG 1.1:34 DEBUG REGEXP: .*but failed to open url.*

atest/run.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@
4040

4141
import platform
4242
import time
43+
from unittest import runner
4344
import zipfile
4445
from contextlib import contextmanager
4546
import os
@@ -211,7 +212,9 @@ def execute_tests(interpreter, browser, rf_options, grid, event_firing, port):
211212
if platform.system() == "Darwin":
212213
runner.append("--exclude")
213214
runner.append("SKIP_ON_MAC")
214-
215+
if platform.system() == "Windows":
216+
runner.append("--exclude")
217+
runner.append("SKIP_ON_WINDOWS")
215218
options.extend([opt.format(browser=browser) for opt in ROBOT_OPTIONS])
216219
if rf_options:
217220
options += rf_options

0 commit comments

Comments
 (0)