syncloud-lib 309__tar.gz → 311__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (53) hide show
  1. {syncloud-lib-309/syncloud_lib.egg-info → syncloud-lib-311}/PKG-INFO +1 -1
  2. {syncloud-lib-309 → syncloud-lib-311/syncloud_lib.egg-info}/PKG-INFO +1 -1
  3. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/integration/conftest.py +11 -5
  4. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/integration/selenium_wrapper.py +15 -2
  5. syncloud-lib-311/version +1 -0
  6. syncloud-lib-309/version +0 -1
  7. {syncloud-lib-309 → syncloud-lib-311}/LICENSE +0 -0
  8. {syncloud-lib-309 → syncloud-lib-311}/MANIFEST.in +0 -0
  9. {syncloud-lib-309 → syncloud-lib-311}/setup.cfg +0 -0
  10. {syncloud-lib-309 → syncloud-lib-311}/setup.py +0 -0
  11. {syncloud-lib-309 → syncloud-lib-311}/syncloud_lib.egg-info/SOURCES.txt +0 -0
  12. {syncloud-lib-309 → syncloud-lib-311}/syncloud_lib.egg-info/dependency_links.txt +0 -0
  13. {syncloud-lib-309 → syncloud-lib-311}/syncloud_lib.egg-info/requires.txt +0 -0
  14. {syncloud-lib-309 → syncloud-lib-311}/syncloud_lib.egg-info/top_level.txt +0 -0
  15. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/__init__.py +0 -0
  16. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/application/__init__.py +0 -0
  17. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/application/config.py +0 -0
  18. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/application/connection.py +0 -0
  19. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/application/paths.py +0 -0
  20. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/application/ports.py +0 -0
  21. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/application/service.py +0 -0
  22. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/application/storage.py +0 -0
  23. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/application/urls.py +0 -0
  24. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/application/users.py +0 -0
  25. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/error.py +0 -0
  26. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/fs.py +0 -0
  27. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/gen.py +0 -0
  28. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/http.py +0 -0
  29. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/integration/__init__.py +0 -0
  30. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/integration/device.py +0 -0
  31. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/integration/hosts.py +0 -0
  32. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/integration/installer.py +0 -0
  33. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/integration/loop.py +0 -0
  34. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/integration/screenshots.py +0 -0
  35. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/integration/ssh.py +0 -0
  36. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/json/__init__.py +0 -0
  37. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/json/convertible.py +0 -0
  38. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/linux.py +0 -0
  39. {syncloud-lib-309 → syncloud-lib-311}/syncloudlib/logger.py +0 -0
  40. {syncloud-lib-309 → syncloud-lib-311}/test/application/test_connection.py +0 -0
  41. {syncloud-lib-309 → syncloud-lib-311}/test/application/test_paths.py +0 -0
  42. {syncloud-lib-309 → syncloud-lib-311}/test/application/test_service.py +0 -0
  43. {syncloud-lib-309 → syncloud-lib-311}/test/application/test_storage.py +0 -0
  44. {syncloud-lib-309 → syncloud-lib-311}/test/application/test_urls.py +0 -0
  45. {syncloud-lib-309 → syncloud-lib-311}/test/integration/test_hosts.py +0 -0
  46. {syncloud-lib-309 → syncloud-lib-311}/test/integration/test_installer.py +0 -0
  47. {syncloud-lib-309 → syncloud-lib-311}/test/integration/test_loop.py +0 -0
  48. {syncloud-lib-309 → syncloud-lib-311}/test/integration/test_ssh.py +0 -0
  49. {syncloud-lib-309 → syncloud-lib-311}/test/json/test_convertible.py +0 -0
  50. {syncloud-lib-309 → syncloud-lib-311}/test/test_fs.py +0 -0
  51. {syncloud-lib-309 → syncloud-lib-311}/test/test_gen.py +0 -0
  52. {syncloud-lib-309 → syncloud-lib-311}/test/test_linux.py +0 -0
  53. {syncloud-lib-309 → syncloud-lib-311}/test/test_logger.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: syncloud-lib
3
- Version: 309
3
+ Version: 311
4
4
  Summary: Syncloud common library
5
5
  Home-page: https://github.com/syncloud/lib
6
6
  Author: Syncloud
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: syncloud-lib
3
- Version: 309
3
+ Version: 311
4
4
  Summary: Syncloud common library
5
5
  Home-page: https://github.com/syncloud/lib
6
6
  Author: Syncloud
@@ -159,8 +159,8 @@ def new_chrome_driver(user_agent, hub_url):
159
159
  )
160
160
 
161
161
 
162
- @pytest.fixture(scope="module")
163
- def driver(ui_mode, browser, browser_height):
162
+ @pytest.fixture(scope="session")
163
+ def driver(ui_mode, browser, browser_height, request):
164
164
  hub_url = 'http://selenium:4444/wd/hub'
165
165
  user_agent = "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:104.0) Gecko/20100101 Firefox/100.0"
166
166
  width = 1024
@@ -173,6 +173,12 @@ def driver(ui_mode, browser, browser_height):
173
173
  else:
174
174
  driver = new_chrome_driver(user_agent, hub_url)
175
175
  driver.set_window_rect(0, 0, width, browser_height)
176
+
177
+ def driver_quit():
178
+ driver.quit()
179
+
180
+ request.addfinalizer(driver_quit)
181
+
176
182
  return driver
177
183
 
178
184
 
@@ -225,6 +231,6 @@ def selenium_timeout():
225
231
  return 300
226
232
 
227
233
 
228
- @pytest.fixture(scope="module")
229
- def selenium(driver, ui_mode, screenshot_dir, app_domain, selenium_timeout):
230
- return SeleniumWrapper(driver, ui_mode, screenshot_dir, app_domain, selenium_timeout)
234
+ @pytest.fixture(scope="session")
235
+ def selenium(driver, ui_mode, screenshot_dir, app_domain, selenium_timeout, browser):
236
+ return SeleniumWrapper(driver, ui_mode, screenshot_dir, app_domain, selenium_timeout, browser)
@@ -7,11 +7,12 @@ from selenium.webdriver.support import expected_conditions
7
7
 
8
8
 
9
9
  class SeleniumWrapper:
10
- def __init__(self, driver, ui_mode, screenshot_dir, app_domain, timeout):
10
+ def __init__(self, driver, ui_mode, screenshot_dir, app_domain, timeout, browser):
11
11
  self.app_domain = app_domain
12
12
  self.screenshot_dir = screenshot_dir
13
13
  self.ui_mode = ui_mode
14
14
  self.driver = driver
15
+ self.browser = browser
15
16
  self.wait_driver = WebDriverWait(self.driver, timeout)
16
17
 
17
18
  def find_by_xpath(self, xpath):
@@ -47,7 +48,6 @@ class SeleniumWrapper:
47
48
  self.wait_or_screenshot(expected_conditions.presence_of_element_located((by, value)))
48
49
  return self.driver.find_element(by, value)
49
50
 
50
-
51
51
  def exists_by(self, by, value, timeout=10):
52
52
  driver = WebDriverWait(self.driver, timeout)
53
53
  cond = expected_conditions.visibility_of_element_located((by, value))
@@ -88,3 +88,16 @@ class SeleniumWrapper:
88
88
 
89
89
  def open_app(self, path=''):
90
90
  self.driver.get("https://{0}{1}".format(self.app_domain, path))
91
+
92
+ def log(self):
93
+ if self.browser != "chrome":
94
+ print("browser logs are only supported in chrome")
95
+ return
96
+
97
+ try:
98
+ for entry in self.driver.get_log('browser'):
99
+ print("---")
100
+ print(entry)
101
+ except Exception as e:
102
+ print("error")
103
+ print(e)
@@ -0,0 +1 @@
1
+ 311
syncloud-lib-309/version DELETED
@@ -1 +0,0 @@
1
- 309
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes