Skip to main content
Stack Overflow
  1. About
  2. For Teams
Filter by
Sorted by
Tagged with
-2 votes
1 answer
69 views

I have an app for listing my books. I want to test my code in chrome and firefox both, using the fixture in my database but without touching the real database. In the database I have some data for the ...
Best practices
1 vote
0 replies
45 views

I have an ETL build with sqlalchemy. To test it, we are using postgres in a docker container through pytest-docker. But because on some computer, spinning docker container takes some time, we also ...
0 votes
1 answer
142 views

I'm learning auto tests in python, and in one video a guy using Mozilla for tests and he uses the following code block: import pytest from selenium import webdriver from selenium.webdriver.chrome....
0 votes
2 answers
116 views

I'm trying to extend a fixture: that means not only overriding, but partially reusing the old one. For example, in the code below the fixture Test.values uses the fixture values and concatenates lists ...
0 votes
1 answer
66 views

I would like to automate disabling subscriptions for 100 stores on a website. I have clicked this together once in Firefox and now I need help on how to have Selenium loop through the steps while ...
1 vote
3 answers
253 views

We use a feature‐testing approach, where each Playwright test file covers an entire feature from start to finish. In these files, I generate random data (e.g., school name, leader email) at the module ...
1 vote
0 answers
78 views

I have Databricks asset bundles and writing unit tests for functions in notebooks using pytest. I create spark session via pytest.fixture, my problem is the scope of Spark. @pytest.fixture(scope="...
1 vote
1 answer
116 views

I'm refactoring a suite of tests and pytest fixtures, and need to locate all usages of a fixture within the test suite. The 'Find all references' function of VSCode is what I'd normally use when ...
1 vote
2 answers
146 views

I'm very baffled and a little concerned to discover the following behaviour where I have two tests and two fixtures. import pytest @pytest.fixture def new_object(): return list() @pytest.fixture ...
Bill's user avatar
  • 11.8k
0 votes
0 answers
29 views

I've been bashing my head into this wall for a while. I'm testing a bunch of hardware and each piece of hardware has child objects that I also have written tests for. So my issue is that I have a lot ...
0 votes
1 answer
47 views

I have some example pytest code like this, simplified for this question: # conftest.py a=[0,1,2,3] @pytest.fixture(params=a) def simple_fixture(request): return request.param #test_my_script.py @...
2 votes
1 answer
117 views

The following unit test, purposely blank class CustomMailerTest < ActionMailer::TestCase test "message_email" do end end where the class CustomMailer defines a message_email method. ...
0 votes
0 answers
54 views

In my project, we have 1000+ fixtures (mock JSON) files. I am required to find a way to remove all these JSON files, and use .mock() methods instead. Here is an example: struct Person { var name: ...
2 votes
1 answer
105 views

I am trying to understand how and when return values from pytest fixtures are cached. In my understanding, the goal of fixtures (in particular session-scoped fixtures) is that they are called only ...
0 votes
0 answers
44 views

I am writing an unit test where I need to mock api behavior, there are two parts of question. Right now I am using fixture which works fine but I don't really understand the mock works here, I don't ...

15 30 50 per page
1
2 3 4 5
...
117

AltStyle によって変換されたページ (->オリジナル) /