From 23ac74ffa93e0cc25c4b9d78ef38e5202077a2ae Mon Sep 17 00:00:00 2001 From: HelioGuilherme66 Date: Tue, 17 Nov 2015 00:31:54 +0000 Subject: [PATCH 1/3] Adds ignoring "--dryrun" to rebot to allow getting the report and log. Changes a flag to True to allow running unit tests in Fedora 22. --- test/run_tests.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/run_tests.py b/test/run_tests.py index 673db64e6..db45ac62a 100755 --- a/test/run_tests.py +++ b/test/run_tests.py @@ -67,6 +67,10 @@ def process_output(args): call(['python', os.path.join(env.RESOURCES_DIR, 'statuschecker.py'), os.path.join(env.RESULTS_DIR, 'output.xml')]) rebot = 'rebot' if os.sep == '/' else 'rebot.bat' + try: + args.remove('--dryrun') + except TypeError: + pass rebot_cmd = [rebot] + [ arg % ARG_VALUES for arg in REBOT_ARGS ] + args + \ [os.path.join(ARG_VALUES['outdir'], 'output.xml') ] print('') From fce75e077827ecec02cc8d81dc40c4cec570ef2f Mon Sep 17 00:00:00 2001 From: HelioGuilherme66 Date: Tue, 17 Nov 2015 22:36:12 +0000 Subject: [PATCH 2/3] Replaces try/exception by if '--dryrun' in args. --- test/run_tests.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/test/run_tests.py b/test/run_tests.py index db45ac62a..9507e6ade 100755 --- a/test/run_tests.py +++ b/test/run_tests.py @@ -67,10 +67,7 @@ def process_output(args): call(['python', os.path.join(env.RESOURCES_DIR, 'statuschecker.py'), os.path.join(env.RESULTS_DIR, 'output.xml')]) rebot = 'rebot' if os.sep == '/' else 'rebot.bat' - try: - args.remove('--dryrun') - except TypeError: - pass + if '--dryrun' in args: args.remove('--dryrun') rebot_cmd = [rebot] + [ arg % ARG_VALUES for arg in REBOT_ARGS ] + args + \ [os.path.join(ARG_VALUES['outdir'], 'output.xml') ] print('') From 14f9b0561d75fde34351959d7f68784c16806613 Mon Sep 17 00:00:00 2001 From: Greg Meece Date: Sat, 10 Dec 2016 15:35:25 -0600 Subject: [PATCH 3/3] Changed docstrings (#549) Changed documentation for set_window_position and get_window_position. --- src/Selenium2Library/keywords/_browsermanagement.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/Selenium2Library/keywords/_browsermanagement.py b/src/Selenium2Library/keywords/_browsermanagement.py index a4fbc7a65..c9c101d74 100644 --- a/src/Selenium2Library/keywords/_browsermanagement.py +++ b/src/Selenium2Library/keywords/_browsermanagement.py @@ -262,7 +262,7 @@ def set_window_size(self, width, height): return self._current_browser().set_window_size(width, height) def get_window_position(self): - """Returns current window position as `x` then `y`. + """Returns current window position as `x` then `y` (relative to the left and top of the screen). Example: | ${x} | ${y}= | Get Window Position | @@ -271,13 +271,13 @@ def get_window_position(self): return position['x'], position['y'] def set_window_position(self, x, y): - """Sets the position `x` and `y` of the current window to the specified values. + """Sets the position x and y of the current window (relative to the left and top of the screen) to the specified values. Example: - | Set Window Size | ${1000} | ${0} | - | ${x} | ${y}= | Get Window Position | - | Should Be Equal | ${x} | ${1000} | - | Should Be Equal | ${y} | ${0} | + | Set Window Position | ${8} | ${10} | + | ${x} | ${y}= | Get Window Position | + | Should Be Equal | ${x} | ${8} | + | Should Be Equal | ${y} | ${10} | """ return self._current_browser().set_window_position(x, y)