{"action":"created","issue":{"url":"https://api.github.com/repos/pytest-dev/pytest/issues/4130","repository_url":"https://api.github.com/repos/pytest-dev/pytest","labels_url":"https://api.github.com/repos/pytest-dev/pytest/issues/4130/labels{/name}","comments_url":"https://api.github.com/repos/pytest-dev/pytest/issues/4130/comments","events_url":"https://api.github.com/repos/pytest-dev/pytest/issues/4130/events","html_url":"https://github.com/pytest-dev/pytest/issues/4130","id":369800313,"node_id":"MDU6SXNzdWUzNjk4MDAzMTM=","number":4130,"title":"How would  you structure a pytest project with the following characteristics ?","user":{"login":"david-fliguer-ws","id":35069943,"node_id":"MDQ6VXNlcjM1MDY5OTQz","avatar_url":"https://avatars2.githubusercontent.com/u/35069943?v=4","gravatar_id":"","url":"https://api.github.com/users/david-fliguer-ws","html_url":"https://github.com/david-fliguer-ws","followers_url":"https://api.github.com/users/david-fliguer-ws/followers","following_url":"https://api.github.com/users/david-fliguer-ws/following{/other_user}","gists_url":"https://api.github.com/users/david-fliguer-ws/gists{/gist_id}","starred_url":"https://api.github.com/users/david-fliguer-ws/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/david-fliguer-ws/subscriptions","organizations_url":"https://api.github.com/users/david-fliguer-ws/orgs","repos_url":"https://api.github.com/users/david-fliguer-ws/repos","events_url":"https://api.github.com/users/david-fliguer-ws/events{/privacy}","received_events_url":"https://api.github.com/users/david-fliguer-ws/received_events","type":"User","site_admin":false},"labels":[{"id":224849198,"node_id":"MDU6TGFiZWwyMjQ4NDkxOTg=","url":"https://api.github.com/repos/pytest-dev/pytest/labels/type:%20question","name":"type: question","color":"cc317c","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":8,"created_at":"2018-10-13T13:03:06Z","updated_at":"2018-10-17T10:37:07Z","closed_at":null,"author_association":"NONE","body":"Hi, we would like to dome some refactoring to our automation project.\r\n\r\nWe use python and pytest.\r\n\r\nWe would like to have a .py file for each test, like this\r\n\r\ntest_one.py\r\ntest_two.py\r\n\r\nEach test should have its own setup and teardown.\r\n\r\nAdditionally I need to execute some actions only once before all the test run and those actions might define variables that I will need on the setup, run and teardown of the tests (This I was thinking to do on a separate conftest.py with a fixture with scope=\"session\" but I'm not sure of how can then I use variables defined there in my setup, run and teardown of the tests)\r\n\r\nAlso we would like to be able to run in parallel using pytest-xdist\r\n\r\nHow would you recommend to organize a project with those characteristic (Regarding hierarchy, fixtures, scopes, etc)\r\n\r\nIf you need any more info I can try to be more specific, but I am open to ideas \r\n\r\nThanks !!!"},"comment":{"url":"https://api.github.com/repos/pytest-dev/pytest/issues/comments/430578497","html_url":"https://github.com/pytest-dev/pytest/issues/4130#issuecomment-430578497","issue_url":"https://api.github.com/repos/pytest-dev/pytest/issues/4130","id":430578497,"node_id":"MDEyOklzc3VlQ29tbWVudDQzMDU3ODQ5Nw==","user":{"login":"david-fliguer-ws","id":35069943,"node_id":"MDQ6VXNlcjM1MDY5OTQz","avatar_url":"https://avatars2.githubusercontent.com/u/35069943?v=4","gravatar_id":"","url":"https://api.github.com/users/david-fliguer-ws","html_url":"https://github.com/david-fliguer-ws","followers_url":"https://api.github.com/users/david-fliguer-ws/followers","following_url":"https://api.github.com/users/david-fliguer-ws/following{/other_user}","gists_url":"https://api.github.com/users/david-fliguer-ws/gists{/gist_id}","starred_url":"https://api.github.com/users/david-fliguer-ws/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/david-fliguer-ws/subscriptions","organizations_url":"https://api.github.com/users/david-fliguer-ws/orgs","repos_url":"https://api.github.com/users/david-fliguer-ws/repos","events_url":"https://api.github.com/users/david-fliguer-ws/events{/privacy}","received_events_url":"https://api.github.com/users/david-fliguer-ws/received_events","type":"User","site_admin":false},"created_at":"2018-10-17T10:37:07Z","updated_at":"2018-10-17T10:37:07Z","author_association":"NONE","body":"> if the library you use to download supports setting up file caches, perhaps just set up a cache folder in the pytest cache directory\r\n\r\nI'm sorry but I don't understand what do you mean with this, each run I need to download a new file, I don't want to \"cache\" the file\r\n\r\n"}}
{"actor":{"display_login":"david-fliguer-ws"}}