Skip to content

Require compare-locales in fluent.migrate #47

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

Merged
merged 1 commit into from
Feb 7, 2018

Conversation

stasm
Copy link
Contributor

@stasm stasm commented Feb 7, 2018

Make compare-locales a hard requirement for running and testing fluent.migrate which already largely depends on it anyways. This reduces the complexity of imports as well as the burden of deciding if a TestCase depends on compare-locales or not. It also makes it less probable to accidentally skip migration tests with python -m unittest discover.

The following commands may be used to run tests:

  • python setup.py test - Only syntax tests in tests/syntax will be run. compare-locales is not required.

  • python -m unittest discover - All tests will be run. If compare-locales is missing, tests will error.

    It's possible to run only syntax or only migrate tests by specifying the starting director on the CLI:

    python -m unittest discover -s tests/syntax
    python -m unittest discover -s tests/migrate
    
  • tox - Tox will create different envs one if which is py27-cl. It contains compare-locales and is configured to run both tests/syntax and tests/migrate tests. All other tests only run tests/syntax.

Make compare-locales a hard requirement for running and testing fluent.migrate
which already largely depends on it anyways. This reduces the complexity of
imports as well as the burden of deciding if a TestCase depends on
compare-locales or not. It also makes it less probable to accidentally skip
migration tests with `python -m unittest discover`.

The following commands may be used to run tests:

  - python setup.py test - Only syntax tests in tests/syntax will be run.
    compare-locales is not required.

  - python -m unittest discover - All tests will be run. If compare-locales is
    missing, tests will error.

    It's possible to run only syntax or only migrate tests by specifying the
    starting director on the CLI:

        python -m unittest discover -s tests/syntax
        python -m unittest discover -s tests/migrate

  - tox - Tox will create different envs one if which is py27-cl. It contains
    compare-locales and is configured to run both tests/syntax and
    tests/migrate tests. All other tests only run tests/syntax.
@@ -21,5 +21,6 @@
package_data={
'fluent.migrate': ['cldr_data/*']
},
tests_require=['six']
tests_require=['six'],
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried adding compare-locales here but python setup.py test fails with version conflicts when it tries to install it. compare-locales requires fluent==0.4.4 while python-fluent's master is usually newer than that.

@stasm stasm requested a review from Pike February 7, 2018 10:41
@stasm stasm merged commit babad84 into projectfluent:master Feb 7, 2018
@stasm stasm deleted the migrate-requires-compare-locales branch February 7, 2018 11:21
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.

2 participants