Skip to content

Commit f4da492

Browse files
committed
upload requirements.txt and modify of conftest.py
1 parent 78838df commit f4da492

File tree

3 files changed

+9
-13
lines changed

3 files changed

+9
-13
lines changed

requirements.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
selenium==4.35.0
22
pytest==8.4.2
33
pytest-html==4.1.1
4-
webdriver-manager==4.0.2
54
allure-pytest== 2.15.0
65
pytest-cov== 7.0.0

test/conftest.py

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
11
import pytest
22
import os
33
from selenium import webdriver
4-
from selenium.webdriver.firefox.service import Service as FirefoxService
54
from selenium.webdriver.firefox.options import Options as FirefoxOptions
65
from selenium.webdriver.edge.options import Options as EdgeOptions
7-
from webdriver_manager.firefox import GeckoDriverManager
86
import allure
97

108

@@ -43,10 +41,7 @@ def browser_driver(request):
4341
firefox_options.set_preference("privacy.trackingprotection.enabled", True)
4442
firefox_options.set_preference("dom.disable_open_during_load", True)
4543
firefox_options.page_load_strategy = 'normal'
46-
driver = webdriver.Firefox(
47-
service=FirefoxService(GeckoDriverManager().install()),
48-
options=firefox_options
49-
)
44+
driver = webdriver.Firefox(options=firefox_options)
5045

5146
elif browser_name == "edge":
5247
edge_options = EdgeOptions()
@@ -66,7 +61,9 @@ def browser_driver(request):
6661

6762
edge_options.add_experimental_option("prefs", prefs)
6863
edge_options.add_experimental_option("excludeSwitches", ["enable-automation"])
64+
6965
driver = webdriver.Edge(options=edge_options)
66+
7067
def fin():
7168
if driver:
7269
try:

test/reports/report.html

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -328,7 +328,7 @@
328328
</head>
329329
<body>
330330
<h1 id="title">report.html</h1>
331-
<p>Report generated on 06-Oct-2025 at 15:38:27 by <a href="https://pypi.python.org/pypi/pytest-html">pytest-html</a>
331+
<p>Report generated on 06-Oct-2025 at 15:51:32 by <a href="https://pypi.python.org/pypi/pytest-html">pytest-html</a>
332332
v4.1.1</p>
333333
<div id="environment-header">
334334
<h2>Environment</h2>
@@ -382,10 +382,10 @@ <h2>Environment</h2>
382382
<h2>Summary</h2>
383383
<div class="additional-summary prefix">
384384
</div>
385-
<p class="run-count">1 test took 00:00:54.</p>
385+
<p class="run-count">0/0 test done.</p>
386386
<p class="filter">(Un)check the boxes to filter the results.</p>
387387
<div class="summary__reload">
388-
<div class="summary__reload__button hidden" onclick="location.reload()">
388+
<div class="summary__reload__button " onclick="location.reload()">
389389
<div>There are still tests running. <br />Reload this page to get the latest results!</div>
390390
</div>
391391
</div>
@@ -394,8 +394,8 @@ <h2>Summary</h2>
394394
<div class="filters">
395395
<input checked="true" class="filter" name="filter_checkbox" type="checkbox" data-test-result="failed" disabled/>
396396
<span class="failed">0 Failed,</span>
397-
<input checked="true" class="filter" name="filter_checkbox" type="checkbox" data-test-result="passed" />
398-
<span class="passed">1 Passed,</span>
397+
<input checked="true" class="filter" name="filter_checkbox" type="checkbox" data-test-result="passed" disabled/>
398+
<span class="passed">0 Passed,</span>
399399
<input checked="true" class="filter" name="filter_checkbox" type="checkbox" data-test-result="skipped" disabled/>
400400
<span class="skipped">0 Skipped,</span>
401401
<input checked="true" class="filter" name="filter_checkbox" type="checkbox" data-test-result="xfailed" disabled/>
@@ -429,7 +429,7 @@ <h2>Summary</h2>
429429
</table>
430430
</body>
431431
<footer>
432-
<div id="data-container" data-jsonblob="{&#34;environment&#34;: {&#34;Python&#34;: &#34;3.13.5&#34;, &#34;Platform&#34;: &#34;Windows-11-10.0.26100-SP0&#34;, &#34;Packages&#34;: {&#34;pytest&#34;: &#34;8.4.2&#34;, &#34;pluggy&#34;: &#34;1.6.0&#34;}, &#34;Plugins&#34;: {&#34;allure-pytest&#34;: &#34;2.15.0&#34;, &#34;html&#34;: &#34;4.1.1&#34;, &#34;metadata&#34;: &#34;3.1.1&#34;}}, &#34;tests&#34;: {&#34;test_cart.py::test_verify_cart_items[firefox]&#34;: [{&#34;extras&#34;: [], &#34;result&#34;: &#34;Passed&#34;, &#34;testId&#34;: &#34;test_cart.py::test_verify_cart_items[firefox]&#34;, &#34;duration&#34;: &#34;00:00:37&#34;, &#34;resultsTableRow&#34;: [&#34;&lt;td class=\&#34;col-result\&#34;&gt;Passed&lt;/td&gt;&#34;, &#34;&lt;td class=\&#34;col-testId\&#34;&gt;test_cart.py::test_verify_cart_items[firefox]&lt;/td&gt;&#34;, &#34;&lt;td class=\&#34;col-duration\&#34;&gt;00:00:37&lt;/td&gt;&#34;, &#34;&lt;td class=\&#34;col-links\&#34;&gt;&lt;/td&gt;&#34;], &#34;log&#34;: &#34;----------------------------- Captured stdout call -----------------------------\nItems: [&amp;#x27;Sauce Labs Bike Light&amp;#x27;, &amp;#x27;Sauce Labs Backpack&amp;#x27;], Badge: 2\n---------------------------- Captured log teardown -----------------------------\nWARNING urllib3.connectionpool:connectionpool.py:868 Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by &amp;#x27;NewConnectionError(&amp;#x27;&amp;lt;urllib3.connection.HTTPConnection object at 0x000001EE66B75590&amp;gt;: Failed to establish a new connection: [WinError 10061] No connection could be made because the target machine actively refused it&amp;#x27;)&amp;#x27;: /session/bff8fc7a-7bb1-4719-bfd9-3f8e8e602bb4\nWARNING urllib3.connectionpool:connectionpool.py:868 Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by &amp;#x27;NewConnectionError(&amp;#x27;&amp;lt;urllib3.connection.HTTPConnection object at 0x000001EE66B77750&amp;gt;: Failed to establish a new connection: [WinError 10061] No connection could be made because the target machine actively refused it&amp;#x27;)&amp;#x27;: /session/bff8fc7a-7bb1-4719-bfd9-3f8e8e602bb4\nWARNING urllib3.connectionpool:connectionpool.py:868 Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by &amp;#x27;NewConnectionError(&amp;#x27;&amp;lt;urllib3.connection.HTTPConnection object at 0x000001EE66B85220&amp;gt;: Failed to establish a new connection: [WinError 10061] No connection could be made because the target machine actively refused it&amp;#x27;)&amp;#x27;: /session/bff8fc7a-7bb1-4719-bfd9-3f8e8e602bb4&#34;}]}, &#34;renderCollapsed&#34;: [&#34;passed&#34;], &#34;initialSort&#34;: &#34;result&#34;, &#34;title&#34;: &#34;report.html&#34;}"></div>
432+
<div id="data-container" data-jsonblob="{&#34;environment&#34;: {&#34;Python&#34;: &#34;3.13.5&#34;, &#34;Platform&#34;: &#34;Windows-11-10.0.26100-SP0&#34;, &#34;Packages&#34;: {&#34;pytest&#34;: &#34;8.4.2&#34;, &#34;pluggy&#34;: &#34;1.6.0&#34;}, &#34;Plugins&#34;: {&#34;allure-pytest&#34;: &#34;2.15.0&#34;, &#34;html&#34;: &#34;4.1.1&#34;, &#34;metadata&#34;: &#34;3.1.1&#34;}}, &#34;tests&#34;: {}, &#34;renderCollapsed&#34;: [&#34;passed&#34;], &#34;initialSort&#34;: &#34;result&#34;, &#34;title&#34;: &#34;report.html&#34;}"></div>
433433
<script>
434434
(function(){function r(e,n,t){function o(i,f){if(!n[i]){if(!e[i]){var c="function"==typeof require&&require;if(!f&&c)return c(i,!0);if(u)return u(i,!0);var a=new Error("Cannot find module '"+i+"'");throw a.code="MODULE_NOT_FOUND",a}var p=n[i]={exports:{}};e[i][0].call(p.exports,function(r){var n=e[i][1][r];return o(n||r)},p,p.exports,r,e,n,t)}return n[i].exports}for(var u="function"==typeof require&&require,i=0;i<t.length;i++)o(t[i]);return o}return r})()({1:[function(require,module,exports){
435435
const { getCollapsedCategory, setCollapsedIds } = require('./storage.js')

0 commit comments

Comments
 (0)