-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for 'pytest' #249
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
[tool.pytest.ini_options] | ||
minversion = "6.0" | ||
#addopts = "-ra -q" | ||
testpaths = [ | ||
"test", | ||
] |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +0,0 @@ | ||
# Made 'example_project.main_package' importable as a module | ||
# It is need to complain with bigflow project structure - top-level package X corresponds to project name. | ||
import sys, os.path | ||
sys.path.append(os.path.join(os.path.dirname(__file__), "example_project")) | ||
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# *** autogenerated: don't edit *** | ||
# $source-hash: sha256:690d1edf921b7215a3b1b3e29efc291db86b55ff5d543d64892b06e2874b06c7 | ||
# $source-file: resources/requirements.in | ||
# | ||
# run 'bigflow build-requirements resources/requirements.in' to update this file | ||
|
||
--index-url https://artifactory.allegrogroup.com/artifactory/api/pypi/pypi.python.org/simple | ||
|
||
datetime_truncate==1.1.0 | ||
# via -r resources/requirements.in | ||
freezegun==0.3.14 | ||
# via -r resources/requirements_base.in | ||
python-dateutil==2.8.1 | ||
# via freezegun | ||
schedule==1.1.0 | ||
# via -r resources/requirements_base.in | ||
six==1.15.0 | ||
# via | ||
# datetime-truncate | ||
# freezegun | ||
# python-dateutil | ||
typing==3.7.4.3 | ||
# via datetime-truncate |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -31,7 +31,7 @@ class _BaseBuildReflectTest( | |
mixins.PrototypedDirMixin, | ||
unittest.TestCase, | ||
): | ||
proto_dir = "build/bf-projects/bf_selfbuild_project" | ||
proto_dir = "buildd/bf-projects/bf_selfbuild_project" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. why buildd instead of build? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 'pytest' ignores 'build' and 'dist' directories by default. pytest-dev/pytest#1544 |
||
|
||
def runpy_n_dump(self, func_name: str): | ||
mod, _ = func_name.rsplit(".", 1) | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Now 'TEST_PROJECT_PATH' is different for each test (tmp directory) and redefined in
TestCase.setUp