cucu 1.3.8__tar.gz → 1.3.9__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.

Potentially problematic release.


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

Files changed (93) hide show
  1. {cucu-1.3.8 → cucu-1.3.9}/PKG-INFO +1 -1
  2. {cucu-1.3.8 → cucu-1.3.9}/pyproject.toml +1 -1
  3. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/ansi_parser.py +2 -1
  4. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/db.py +10 -5
  5. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/formatter/junit.py +3 -1
  6. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/formatter/rundb.py +5 -1
  7. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/reporter/templates/scenario.html +3 -0
  8. {cucu-1.3.8 → cucu-1.3.9}/README.md +0 -0
  9. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/__init__.py +0 -0
  10. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/behave_tweaks.py +0 -0
  11. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/browser/__init__.py +0 -0
  12. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/browser/core.py +0 -0
  13. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/browser/frames.py +0 -0
  14. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/browser/selenium.py +0 -0
  15. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/browser/selenium_tweaks.py +0 -0
  16. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/cli/__init__.py +0 -0
  17. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/cli/core.py +0 -0
  18. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/cli/run.py +0 -0
  19. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/cli/steps.py +0 -0
  20. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/cli/thread_dumper.py +0 -0
  21. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/config.py +0 -0
  22. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/edgedriver_autoinstaller/README.md +0 -0
  23. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/edgedriver_autoinstaller/__init__.py +0 -0
  24. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/edgedriver_autoinstaller/utils.py +0 -0
  25. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/environment.py +0 -0
  26. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/external/jquery/jquery-3.5.1.min.js +0 -0
  27. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/formatter/__init__.py +0 -0
  28. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/formatter/cucu.py +0 -0
  29. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/formatter/json.py +0 -0
  30. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/fuzzy/__init__.py +0 -0
  31. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/fuzzy/core.py +0 -0
  32. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/fuzzy/fuzzy.js +0 -0
  33. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/helpers.py +0 -0
  34. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/hooks.py +0 -0
  35. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/init_data/.gitignore +0 -0
  36. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/init_data/README.md +0 -0
  37. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/init_data/cucurc.yml +0 -0
  38. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/init_data/data/www/example.html +0 -0
  39. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/init_data/features/cucurc.yml +0 -0
  40. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/init_data/features/environment.py +0 -0
  41. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/init_data/features/example.feature +0 -0
  42. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/init_data/features/lint_rules/sid.yaml +0 -0
  43. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/init_data/features/steps/__init__.py +0 -0
  44. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/init_data/features/steps/my_steps.py +0 -0
  45. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/language_server/__init__.py +0 -0
  46. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/language_server/core.py +0 -0
  47. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/lint/__init__.py +0 -0
  48. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/lint/linter.py +0 -0
  49. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/lint/rules/format.yaml +0 -0
  50. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/logger.py +0 -0
  51. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/matcher/__init__.py +0 -0
  52. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/matcher/core.py +0 -0
  53. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/page_checks.py +0 -0
  54. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/reporter/__init__.py +0 -0
  55. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/reporter/external/bootstrap.min.css +0 -0
  56. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/reporter/external/bootstrap.min.js +0 -0
  57. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/reporter/external/dataTables.bootstrap.min.css +0 -0
  58. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/reporter/external/dataTables.bootstrap.min.js +0 -0
  59. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/reporter/external/jquery-3.5.1.min.js +0 -0
  60. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/reporter/external/jquery.dataTables.min.js +0 -0
  61. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/reporter/external/popper.min.js +0 -0
  62. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/reporter/favicon.png +0 -0
  63. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/reporter/html.py +0 -0
  64. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/reporter/templates/feature.html +0 -0
  65. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/reporter/templates/flat.html +0 -0
  66. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/reporter/templates/index.html +0 -0
  67. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/reporter/templates/layout.html +0 -0
  68. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/__init__.py +0 -0
  69. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/base_steps.py +0 -0
  70. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/browser_steps.py +0 -0
  71. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/button_steps.py +0 -0
  72. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/checkbox_steps.py +0 -0
  73. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/command_steps.py +0 -0
  74. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/draggable_steps.py +0 -0
  75. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/dropdown_steps.py +0 -0
  76. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/file_input_steps.py +0 -0
  77. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/filesystem_steps.py +0 -0
  78. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/flow_control_steps.py +0 -0
  79. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/image_steps.py +0 -0
  80. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/input_steps.py +0 -0
  81. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/link_steps.py +0 -0
  82. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/menuitem_steps.py +0 -0
  83. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/platform_steps.py +0 -0
  84. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/radio_steps.py +0 -0
  85. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/section_steps.py +0 -0
  86. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/step_utils.py +0 -0
  87. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/tab_steps.py +0 -0
  88. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/table_steps.py +0 -0
  89. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/tables.js +0 -0
  90. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/text_steps.py +0 -0
  91. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/variable_steps.py +0 -0
  92. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/steps/webserver_steps.py +0 -0
  93. {cucu-1.3.8 → cucu-1.3.9}/src/cucu/utils.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: cucu
3
- Version: 1.3.8
3
+ Version: 1.3.9
4
4
  Summary: Easy BDD web testing
5
5
  Keywords: cucumber,selenium,behave
6
6
  Author: Domino Data Lab, Rodney Gomes, Cedric Young, Xin Dong, Kavya Yakkati, Kevin Garton, Joy Liao
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "cucu"
3
- version = "1.3.8"
3
+ version = "1.3.9"
4
4
  description = "Easy BDD web testing"
5
5
  readme = "README.md"
6
6
  license = { text = "The Clear BSD License" }
@@ -25,12 +25,13 @@ TRANSLATION = (
25
25
  ESC_SEQ + "55": "", # ignore HOME (num keypad)
26
26
  ESC_SEQ + "56": "", # ignore UP ARROW (num keypad)
27
27
  ESC_SEQ + "57": "", # ignore PAGE UP (num keypad)
28
+ ESC_SEQ + "1A": "", # ignore move cursor up one line
28
29
  }
29
30
  )
30
31
  RE_TO_HTML = re.compile("|".join(map(re.escape, TRANSLATION)))
31
32
 
32
33
  RE_TO_REMOVE = re.compile(
33
- r"\x1b\[(0;)?[0-9A-F]{1,2}m"
34
+ r"\x1b\[(0;)?[0-9A-F]{1,2}[mA]:?"
34
35
  ) # detect hex values, not just decimal digits
35
36
 
36
37
 
@@ -123,16 +123,16 @@ class step(BaseModel):
123
123
  duration = FloatField(null=True)
124
124
  start_at = DateTimeField(null=True)
125
125
  end_at = DateTimeField(null=True)
126
- stdout = JSONField(null=True)
127
- stderr = JSONField(null=True)
126
+ stdout = JSONField()
127
+ stderr = JSONField()
128
128
  error_message = JSONField(null=True)
129
129
  exception = JSONField(null=True)
130
- debug_output = TextField(null=True)
131
- browser_info = JSONField(null=True)
130
+ debug_output = TextField()
131
+ browser_info = JSONField()
132
132
  text = JSONField(null=True)
133
133
  table_data = JSONField(null=True)
134
134
  location = TextField()
135
- browser_logs = TextField(null=True)
135
+ browser_logs = TextField()
136
136
  screenshots = JSONField(null=True)
137
137
 
138
138
 
@@ -213,6 +213,11 @@ def start_step_record(step_obj, scenario_run_id):
213
213
  is_substep=getattr(step_obj, "is_substep", False),
214
214
  has_substeps=getattr(step_obj, "has_substeps", False),
215
215
  section_level=getattr(step_obj, "section_level", None),
216
+ browser_info="",
217
+ browser_logs="",
218
+ debug_output="",
219
+ stderr=[],
220
+ stdout=[],
216
221
  )
217
222
 
218
223
 
@@ -10,6 +10,7 @@ from behave.model_core import Status
10
10
  from bs4.formatter import XMLFormatter
11
11
  from tenacity import RetryError
12
12
 
13
+ from cucu.ansi_parser import remove_ansi
13
14
  from cucu.config import CONFIG
14
15
  from cucu.utils import ellipsize_filename
15
16
 
@@ -286,7 +287,8 @@ class CucuJUnitFormatter(Formatter):
286
287
  if scenario["failure"] is not None:
287
288
  failure_message = "\n".join(scenario["failure"])
288
289
  failure = bs4.Tag(name="failure")
289
- failure.append(bs4.CData(failure_message))
290
+ cleaned_failure_message = remove_ansi(failure_message)
291
+ failure.append(bs4.CData(cleaned_failure_message))
290
292
  testcase.append(failure)
291
293
 
292
294
  if scenario["skipped"] is not None:
@@ -132,6 +132,8 @@ class RundbFormatter(Formatter):
132
132
  def scenario(self, scenario):
133
133
  """Called before a scenario is executed (or ScenarioOutline scenarios)."""
134
134
  self._finish_scenario()
135
+ # Set after CONFIG.restore() in environment.before_scenario()
136
+ CONFIG["FEATURE_RUN_ID"] = scenario.feature.feature_run_id
135
137
 
136
138
  self.this_scenario = scenario
137
139
  self.this_steps = []
@@ -139,7 +141,9 @@ class RundbFormatter(Formatter):
139
141
  scenario_run_id_seed = (
140
142
  f"{scenario.feature.feature_run_id}_{time.perf_counter()}"
141
143
  )
142
- scenario.scenario_run_id = generate_short_id(scenario_run_id_seed)
144
+ CONFIG["SCENARIO_RUN_ID"] = scenario.scenario_run_id = (
145
+ generate_short_id(scenario_run_id_seed)
146
+ )
143
147
  scenario.custom_data = {}
144
148
 
145
149
  # feature.scenarios is a mix of Scenario and ScenarioOutline objects with their own scenarios list
@@ -87,6 +87,9 @@
87
87
  {% endif %}
88
88
  {% if step['result'] is defined %}
89
89
  {% set step_status = step['result']['status'] %}
90
+ {% if step['result']['status'] == 'skipped' %}
91
+ {% set step_status = 'untested' %}
92
+ {% endif %}
90
93
  {% if step['result']['status'] in ('failed', 'passed') and step["result"]["timestamp"] %}
91
94
  {% set step_timing = "{} for {:.3f}s".format(step["result"]["timestamp"].strftime("%H:%M:%S"), step["result"]["duration"]) %}
92
95
  {% set step_start = step["result"]["timestamp"] %}
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes