cucu 1.3.5__py3-none-any.whl → 1.3.6__py3-none-any.whl

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.

Potentially problematic release.


This version of cucu might be problematic. Click here for more details.

cucu/environment.py CHANGED
@@ -215,6 +215,23 @@ def after_scenario(ctx, scenario):
215
215
  for timer_name in ctx.step_timers:
216
216
  logger.warning(f'timer "{timer_name}" was never stopped/recorded')
217
217
 
218
+ browser_info = {"has_browser": False}
219
+
220
+ if len(ctx.browsers) != 0:
221
+ try:
222
+ tab_info = ctx.browser.get_tab_info()
223
+ all_tabs = ctx.browser.get_all_tabs_info()
224
+ browser_info = {
225
+ "has_browser": True,
226
+ "current_tab_index": tab_info["index"],
227
+ "all_tabs": all_tabs,
228
+ "browser_type": ctx.browser.driver.name,
229
+ }
230
+ except Exception as e:
231
+ logger.error(f"Error getting browser info: {e}")
232
+
233
+ scenario.browser_info = browser_info
234
+
218
235
  run_after_scenario_hook(ctx, scenario, download_mht_data)
219
236
 
220
237
  # run after all scenario hooks in 'lifo' order.
@@ -227,22 +244,12 @@ def after_scenario(ctx, scenario):
227
244
 
228
245
  CONFIG["__CUCU_AFTER_THIS_SCENARIO_HOOKS"] = []
229
246
 
230
- browser_info = {"has_browser": False}
231
247
  if CONFIG.true("CUCU_KEEP_BROWSER_ALIVE"):
232
248
  logger.debug("keeping browser alive between sessions")
233
249
  elif len(ctx.browsers) != 0:
234
- tab_info = ctx.browser.get_tab_info()
235
- all_tabs = ctx.browser.get_all_tabs_info()
236
- browser_info = {
237
- "current_tab_index": tab_info["index"],
238
- "all_tabs": all_tabs,
239
- "browser_type": ctx.browser.driver.name,
240
- }
241
-
242
250
  logger.debug("quitting browser between sessions")
243
251
  run_after_scenario_hook(ctx, scenario, cleanup_browsers)
244
252
 
245
- scenario.browser_info = browser_info
246
253
 
247
254
  cucu_config_path = ctx.scenario_logs_dir / "cucu.config.yaml.txt"
248
255
  with open(cucu_config_path, "w") as config_file:
@@ -1,10 +1,10 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: cucu
3
- Version: 1.3.5
3
+ Version: 1.3.6
4
4
  Summary: Easy BDD web testing
5
5
  Keywords: cucumber,selenium,behave
6
- Author: Domino Data Lab, Rodney Gomes, Cedric Young, Xin Dong, Kavya, Kevin Garton, Joy Liao
7
- Author-email: Domino Data Lab <open-source@dominodatalab.com>, Rodney Gomes <107359+rlgomes@users.noreply.github.com>, Cedric Young <4129217+ccedricyoung@users.noreply.github.com>, Xin Dong <104880864+ddl-xin@users.noreply.github.com>, Kavya <91882851+ddl-kavya@users.noreply.github.com>, Kevin Garton <71028750+ddl-kgarton@users.noreply.github.com>, Joy Liao <107583686+ddl-joy-liao@users.noreply.github.com>
6
+ Author: Domino Data Lab, Rodney Gomes, Cedric Young, Xin Dong, Kavya Yakkati, Kevin Garton, Joy Liao
7
+ Author-email: Domino Data Lab <open-source@dominodatalab.com>, Rodney Gomes <107359+rlgomes@users.noreply.github.com>, Cedric Young <4129217+ccedricyoung@users.noreply.github.com>, Xin Dong <104880864+ddl-xin@users.noreply.github.com>, Kavya Yakkati <91882851+ddl-kavya@users.noreply.github.com>, Kevin Garton <71028750+ddl-kgarton@users.noreply.github.com>, Joy Liao <107583686+ddl-joy-liao@users.noreply.github.com>
8
8
  License: The Clear BSD License
9
9
  Classifier: Development Status :: 4 - Beta
10
10
  Classifier: Environment :: Console
@@ -16,7 +16,7 @@ cucu/db.py,sha256=hQg54M7LvCIO-5Pluw5CR0jvC_0MXxrUAyhctoLCGKU,11865
16
16
  cucu/edgedriver_autoinstaller/README.md,sha256=tDkAWIqgRdCjt-oX1nYqikIC_FfiOEM2-pc5S5VbRLo,84
17
17
  cucu/edgedriver_autoinstaller/__init__.py,sha256=fo6xJJPvcc5Xvni8epXfxDoPxJH5_b6Vk2jD9JTwfRs,969
18
18
  cucu/edgedriver_autoinstaller/utils.py,sha256=iRKTww77CGaTAntt_QDvxlKPxpMU4otx95OeD97khcM,6802
19
- cucu/environment.py,sha256=snMpafsBsBGRQwzf2MwfccQuZjDGkzUtnOicHyy6hQw,13714
19
+ cucu/environment.py,sha256=312Vo-rzz09Ag_XsLovxd5rW_M5QE_-uce8lvLzNtOE,13917
20
20
  cucu/external/jquery/jquery-3.5.1.min.js,sha256=9_aliU8dGd2tb6OSsuzixeV4y_faTqgFtohetphbbj0,89476
21
21
  cucu/formatter/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
22
22
  cucu/formatter/cucu.py,sha256=jHi6W9STRQjDy0j1P_HLLlBTPsS6EvUyvqeUjtWs3vM,9291
@@ -87,7 +87,7 @@ cucu/steps/text_steps.py,sha256=Jj_GHoHeemNwVdUOdqcehArNp7WM-WMjljA4w0pLXuw,2576
87
87
  cucu/steps/variable_steps.py,sha256=WSctH3_xcxjijGPYZlxp-foC_SIAAKtF__saNtgZJbk,2966
88
88
  cucu/steps/webserver_steps.py,sha256=wWkpSvcSMdiskPkh4cqlepWx1nkvEpTU2tRXQmPDbyo,1410
89
89
  cucu/utils.py,sha256=LCcs8sMzvdvH05N8P5QYO4lO6j-_PQC530mEAD96go8,10957
90
- cucu-1.3.5.dist-info/WHEEL,sha256=4n27za1eEkOnA7dNjN6C5-O2rUiw6iapszm14Uj-Qmk,79
91
- cucu-1.3.5.dist-info/entry_points.txt,sha256=11WRIhQM7LuUnQg1lAoZQoNvvBvYNN1maDgQS4djwJo,40
92
- cucu-1.3.5.dist-info/METADATA,sha256=Z21XbbuwgJdBjh_x_anWZZTrPDKnqCGTw31VVkmuJBQ,16705
93
- cucu-1.3.5.dist-info/RECORD,,
90
+ cucu-1.3.6.dist-info/WHEEL,sha256=-neZj6nU9KAMg2CnCY6T3w8J53nx1kFGw_9HfoSzM60,79
91
+ cucu-1.3.6.dist-info/entry_points.txt,sha256=11WRIhQM7LuUnQg1lAoZQoNvvBvYNN1maDgQS4djwJo,40
92
+ cucu-1.3.6.dist-info/METADATA,sha256=gSX1DtMVpWVOqHw6YNpVg4qNbkSEEwcjcIAKiuSs47M,16721
93
+ cucu-1.3.6.dist-info/RECORD,,
@@ -1,4 +1,4 @@
1
1
  Wheel-Version: 1.0
2
- Generator: uv 0.8.13
2
+ Generator: uv 0.8.22
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any