Skip to content

Commit

Permalink
Merge pull request #269 from lsst/tickets/DM-11514-afw
Browse files Browse the repository at this point in the history
DM-11514: Fix some pytest problems
  • Loading branch information
timj committed Aug 8, 2017
2 parents ba14e82 + 74c0022 commit b131724
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 11 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ _build.*
*~
*.dSYM/
core.*
.cache/
.sconf_temp
.sconsign.dblite
config.log
Expand Down
14 changes: 5 additions & 9 deletions tests/SConscript
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,12 @@ pybind11_test_modules = ['testTableArchivesLib']

scripts.BasicSConscript.pybind11(pybind11_test_modules)

# copy AFWDATA_DIR to the test's environment
afwdataDir = env.ProductDir("afwdata")
if afwdataDir:
env["ENV"]["AFWDATA_DIR"] = afwdataDir

if not afwdataDir:
testArgs = dict(statistics = "--run_test=!StatisticsTestImages",
background = "--run_test=!BackgroundTestImages",)
scripts.BasicSConscript.tests(noBuildList=[name + '.cc' for name in pybind11_test_modules],
args=testArgs)
else:
# copy AFWDATA_DIR to the test's environment
env["ENV"]["AFWDATA_DIR"] = afwdataDir
scripts.BasicSConscript.tests(noBuildList=[name + '.cc' for name in pybind11_test_modules])
scripts.BasicSConscript.tests(noBuildList=[name + '.cc' for name in pybind11_test_modules],
ignoreList=[name + '.py' for name in pybind11_test_modules])

env.Clean(targets["tests"], "#testTable.fits")
File renamed without changes.
2 changes: 1 addition & 1 deletion tests/test_footprint.py
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,7 @@ class TestMemory(lsst.utils.tests.MemoryTestCase):
pass


def set_module(module):
def setup_module(module):
lsst.utils.tests.init()


Expand Down
2 changes: 1 addition & 1 deletion tests/test_spanSets.py
Original file line number Diff line number Diff line change
Expand Up @@ -417,7 +417,7 @@ class TestMemory(lsst.utils.tests.MemoryTestCase):
pass


def set_module(module):
def setup_module(module):
lsst.utils.tests.init()


Expand Down

0 comments on commit b131724

Please sign in to comment.