Commit graph

75 commits

Author SHA1 Message Date
Todd Gamblin
b5537553f2 Run coverage for the spack install command as well as spack test.
- Also don't run coverage on OSX.
2016-12-30 17:18:19 -08:00
Todd Gamblin
d52c44cba9 Add OSX build to .travis.yml. Clean up .travis.yml (#2689)
* Add OSX build to .travis.yml.  Clean up .travis.yml
* Add gcc/gfortran to the mac brew setup.
2016-12-30 13:59:21 -08:00
Massimiliano Culpo
7ea10e768e unit tests: replace nose with pytest (#2502)
* Porting: substitute nose with ytest

This huge commit substitutes nose with pytest as a testing system. Things done here:

* deleted external/nose as it is no longer used
* moved mock resources in their own directory 'test/mock/'
* ported two tests (cmd/find, build_system) to pytest native syntax as an example
* build_environment, log: used monkeypatch instead of try/catch
* moved global mocking of fetch_cache to an auto-used fixture
* moved global mocking from test/__init__.py to conftest.py
* made `spack test` a wrapper around pytest
* run-unit-tests: avoid running python 2.6 tests under coverage to speed them up
* use `pytest --cov` instead of coverage run to cut down testing time

* mock/packages_test: moved mock yaml configuration to files instead of leaving it in the code as string literals

* concretize.py: ported tests to native pytest, reverted multiprocessing in pytest.ini as it was creating the wrong report for coveralls

* conftest.py, fixtures: added docstrings

* concretize_preferences.py: uses fixtures instead of subclassing MockPackagesTest

* directory_layout.py: uses fixtures instead of subclassing MockPackagesTest

* install.py: uses fixtures instead of subclassing MockPackagesTest

* optional_deps.py: uses fixtures instead of subclassing MockPackagesTest

optional_deps.py: uses fixtures instead of subclassing MockPackagesTest

* packages.py: uses fixtures instead of subclassing MockPackagesTest

* provider_index.py: uses fixtures instead of subclassing MockPackagesTest

* spec_yaml.py: uses fixtures instead of subclassing MockPackagesTest

* multimethod.py: uses fixtures instead of subclassing MockPackagesTest

* install.py: now uses mock_archive_url

* git_fetch.py: uses fixtures instead of subclassing MockPackagesTest

* hg_fetch.py: uses fixtures instead of subclassing MockPackagesTest

* svn_fetch.py, mirror.py: uses fixtures instead of subclassing MockPackagesTest
repo.py: deleted

* test_compiler_cmd.py: uses fixtures instead of subclassing MockPackagesTest

* cmd/module.py, cmd/uninstall.py: uses fixtures instead of subclassing MockDatabase

* database.py: uses fixtures instead of subclassing MockDatabase, removed mock/database

* pytest: uncluttering fixture implementations

* database: changing the scope to 'module'

* config.py: uses fixtures instead of subclassing MockPackagesTest

* spec_dag.py, spec_semantics.py: uses fixtures instead of subclassing MockPackagesTest

* stage.py: uses fixtures instead of subclassing MockPackagesTest. Removed mock directory

* pytest: added docstrings to all the fixtures

* pytest: final cleanup

* build_system_guess.py: fixed naming and docstrings as suggested by @scheibelp

* spec_syntax.py: added expected failure on parsing multiple specs closes #1976

* Add pytest and pytest-cov to Spack externals.

* Make `spack flake8` ignore externals.

* run-unit-tests runs spack test and not pytest.

* Remove all the special stuff for `spack test`

- Remove `conftest.py` magic and all the special case stuff in `bin/spack`

- Spack commands can optionally take unknown arguments, if they want to
  handle them.

- `spack test` is now a command like the others.

- `spack test` now just delegates its arguments to `pytest`, but it does
  it by receiving unknown arguments and NOT taking an explicit
  help argument.

* Fix error in fixtures.

* Improve `spack test` command a bit.

- Now supports an approximation of the old simple interface
- Also supports full pytest options if you want them.

* Use external coverage instead of pytest-cov

* Make coverage use parallel-mode.

* change __init__.py docs to include pytest
2016-12-29 07:48:48 -08:00
Todd Gamblin
089e5b5996 Remove CYAML tests from Spack now that the DB is JSON. (#2487) 2016-12-05 10:31:49 -08:00
Massimiliano Culpo
2634e4909f travis: sphinx does not support python 2.6 anymore (#2485) 2016-12-05 08:27:03 -08:00
Todd Gamblin
db89b534bd travis.yml: Only build master and develop on push 2016-10-30 23:55:00 -07:00
Massimiliano Culpo
9726574846 travis : unit tests will run with and without libyaml (#2024)
* travis : unit tests will run with and without libyaml

* travis : fixed package that are installed
2016-10-15 14:21:50 -07:00
Todd Gamblin
c470ffe1ac Install graphviz before build. 2016-08-30 20:17:12 -07:00
Adam J. Stewart
a235d030ac Fix typos and bugs in Travis config file
Forgot to change one of the TEST_TYPEs to TEST_SUITE.
-eq not working, trying == instead.
Cache doesn't seem to be working, removed.
2016-08-30 15:21:15 -05:00
Adam J. Stewart
732c1985ef Overhaul Spack's CI Infrastructure 2016-08-30 15:20:03 -05:00
alalazo
f4422dc165 qa : fixes #1370 (no flake8 on python 2.6, coveralls only python 2.7) 2016-07-30 18:49:23 +02:00
Todd Gamblin
f158375054 .travis.yml uses a script now.
- user can run the same script.
2016-05-11 01:17:52 -07:00
Todd Gamblin
2aa4387eba Update code style checking.
- Exempt overlong URL lines from checks.
- Omit some of the more painful PEP items.
2016-05-11 00:07:42 -07:00
alalazo
3f20014f33 qa : differentiate framework from packages 2016-05-10 18:45:11 +02:00
alalazo
190c437980 qa : copied flake8 configuration, updated travis.yml 2016-05-10 18:38:30 +02:00
Todd Gamblin
e60f25f209 Move args to .coveragerc 2016-05-10 00:51:08 -07:00
alalazo
1664d1b503 travis : removed external directory from the list under coverage 2016-03-22 15:59:58 +01:00
alalazo
6e847b7d76 Merge branch 'develop' of https://github.com/LLNL/spack into qa/coding_standard
Conflicts:
	.travis.yml
2016-03-22 15:57:35 +01:00
Todd Gamblin
d8a402ae5b Add compiler info and a simple libdwarf build to the checks. 2016-03-15 14:33:10 -07:00
alalazo
4b22c2406c removed redundant references to pep8 2016-02-05 08:56:20 +01:00
alalazo
00185a39d9 reverted email notification 2016-01-19 19:28:38 +01:00
alalazo
ae7c999712 code checking : added flake8 2016-01-19 18:55:18 +01:00
alalazo
f3d62f1d3b code checking : added pep8 and coveralls 2016-01-19 18:29:39 +01:00
Todd Gamblin
55237b094a Use new travis insfrastructure (sudo:false) 2015-11-29 22:09:11 -08:00
Todd Gamblin
45ffcdee7b Add very basic Travis CI support. 2015-11-29 22:02:13 -08:00