Skip to content

Add regression test for parsing multiple specs #1976

Closed
alalazo wants to merge 1 commit intospack:developfrom
epfl-scitas:tests/spec_parser_expected_failure
Closed

Add regression test for parsing multiple specs #1976
alalazo wants to merge 1 commit intospack:developfrom
epfl-scitas:tests/spec_parser_expected_failure

Conversation

@alalazo
Copy link
Copy Markdown
Member

@alalazo alalazo commented Oct 8, 2016

See #1956

@alalazo
Copy link
Copy Markdown
Member Author

alalazo commented Oct 9, 2016

@tgamblin Side question : how long do you think we'll need to support python 2.6 ? It's being deprecated everywhere, including official python.org docs...

@tgamblin
Copy link
Copy Markdown
Member

This is only an expected failure right now b/c the bug hasn't been fixed. So we should switch it back when it's fixed...

I'm sad about Python 2.6. The easy build guys recently did a poll that showed many centers still have it as their default. I'm tempted to drop it sometime in the next year, as I think most sites do offer a 2.7 side install, but who knows. Maybe we could drop it if we can guarantee that Spack can bootstrap Python 2.7 from a 2.6 install... not sure how much work it would be to keep that code path clean.

@alalazo
Copy link
Copy Markdown
Member Author

alalazo commented Oct 10, 2016

This is only an expected failure right now b/c the bug hasn't been fixed. So we should switch it back when it's fixed...

Yes, that was a bad try by my side to insert a failing regression test in the code base without having Travis CI complaining. The next step would have been reporting expected failures as 'Expected failures [bug not yet fixed]' or something like that.

The problem obviously is that 2.6 doesn't know what an expectedFailure is...

@adamjstewart
Copy link
Copy Markdown
Member

For what it's worth, our newest cluster runs CentOS 6 and comes with Python 2.6.6 by default. Our old cluster runs CentOS 5 and comes with Python 2.4.3 by default. So I don't think it's uncommon to find 2.6 (or older) in production.

Sometime this winter we're replacing our old cluster with a new one running CentOS 7. Once development on that stabilizes, we'll be updating the other cluster to CentOS 7 as well.

@tgamblin
Copy link
Copy Markdown
Member

Ok let's keep this open and resolve it when spec parsing is fixed (by removing the expected failure)

@tgamblin tgamblin changed the title spec parsing : added expected failure Add regression test for parsing multiple specs Oct 10, 2016
alalazo added a commit to epfl-scitas/spack that referenced this pull request Dec 19, 2016
@alalazo alalazo mentioned this pull request Dec 22, 2016
2 tasks
@alalazo
Copy link
Copy Markdown
Member Author

alalazo commented Dec 22, 2016

@tgamblin I added this as an expected failure in #2502 . If you agree I'll close this.

tgamblin pushed a commit to epfl-scitas/spack that referenced this pull request Dec 27, 2016
tgamblin pushed a commit to epfl-scitas/spack that referenced this pull request Dec 27, 2016
tgamblin pushed a commit to epfl-scitas/spack that referenced this pull request Dec 28, 2016
@alalazo
Copy link
Copy Markdown
Member Author

alalazo commented Dec 29, 2016

Closing as this is part of #2502

@alalazo alalazo closed this Dec 29, 2016
@alalazo alalazo deleted the tests/spec_parser_expected_failure branch December 29, 2016 11:03
tgamblin pushed a commit that referenced this pull request Dec 29, 2016
* 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
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants