Commit Graph

48 Commits (master)

Author SHA1 Message Date
Manuel Kaufmann 23b20cdb87 Do not run py27 on tox 2019-01-03 16:42:58 +01:00
Manuel Kaufmann 87397f2119 Properly set LANG and LC_ALL environment variables
LANG=C means ASCII and that's why unicode branches/tag tests are
failing.
2018-12-04 13:44:28 +01:00
Eric Holscher 818566bd6c Add travis check for migrations 2018-10-31 11:11:15 -05:00
Santos Gallegos 6a2720cd77 Run codecov 2018-10-19 00:52:00 -05:00
Santos Gallegos 4ee82608af Update description 2018-10-19 00:00:20 -05:00
Santos Gallegos 1bacd1e659 Don't report some files on coverage 2018-10-19 00:00:20 -05:00
Santos Gallegos 12d7b001de Run coverage on travis 2018-10-19 00:00:20 -05:00
Santos Gallegos 3c73fbf10f Skip local settings on testing 2018-09-28 11:59:33 -05:00
Safwan Rahman 54f0106f29 Implement exact match search and rewrite for operator ordering 2018-07-16 09:20:49 +06:00
David Fischer b0810e023b Use "npm run lint" from tox (#4312)
* Use "npm run lint" from tox

* Don't need gulp anymore for CI
2018-07-05 09:52:33 -06:00
Eric Holscher e3c966ff5b Don't change tox yet, just fix this bug 2018-05-30 14:53:51 -04:00
Eric Holscher 6d3b1b7f85 Properly run in nitpicky mode 2018-05-30 14:53:03 -04:00
Eric Holscher 57ea8a1762 Remove CSS override that doesn't exist.
Also remove static path file,
and run our tests with warnings enabled since we can now.
2018-05-30 14:30:57 -04:00
Eric Holscher 242ccaed63
Merge pull request #4052 from stsewd/use-git-python-for-tags
Use gitpython for tags
2018-05-29 11:11:30 -04:00
Eric Holscher c39c770865
Merge pull request #4141 from stsewd/ignore-migrations-coverage
Ignore migrations from coverage report
2018-05-24 12:22:24 -04:00
Santos Gallegos c55322d89d Ignore migrations from coverage report 2018-05-24 10:44:11 -05:00
Santos Gallegos d6292bcb4e Add description to tox env 2018-05-22 23:32:10 -05:00
Santos Gallegos 318d3fa0a4 Check files with recursive option 2018-05-22 23:30:46 -05:00
Santos Gallegos 49e544b365 Use new requirements file 2018-05-22 23:30:46 -05:00
Santos Gallegos eec8189a36 Move to separate env 2018-05-22 23:30:45 -05:00
Santos Gallegos c231285aa4 Expand find command on tox 2018-05-22 23:30:04 -05:00
Santos Gallegos 607e3e2014 Add rstcheck to tox dosc environment 2018-05-22 23:30:04 -05:00
Santos Gallegos f4c53c850a Set magic environment variable 2018-05-16 16:48:26 -05:00
Bernat Gabor 4e43cafada
add description for tox tasks
For example:
default environments:
py27     -> run test suite for the application with python2.7
py36     -> run test suite for the application with python3.6
lint     -> run linter (prospector) to ensure the source code
corresponds to our coding standards
docs     -> build readthedocs documentation

additional environments:
coverage -> run test suite with code coverage for the application with
/usr/bin/python
eslint   -> run the JavaScript linter (requires gulp installed)
2018-03-28 11:15:55 +01:00
Santos Gallegos 3b5cd7c0fb Fix tox env: coverage 2018-03-11 22:29:56 -05:00
Manuel Kaufmann c5753a5b81 Ability to override the creation of the Celery App (#3623)
* Ability to override the creation of the Celery App

* Revert "Ability to override the creation of the Celery App"

This reverts commit d21649cba4e44c4323fe2d4fcaf67cc2a51ff816.

* Use simple settings to reuse the Celery App

* Fix Django settings when running tests
2018-02-22 07:49:50 -07:00
Anthony Johnson ead1f7755d
More fixes 2017-06-14 15:51:00 -07:00
Anthony Johnson 03e94fdda6
Remove extra envs from python version run with tox-travis
This stops multiple envs from running on the py27/py36 test envs
2017-06-14 15:46:56 -07:00
Anthony accc01535c Finish linting on py3ish code (#2949)
* Resolve first round of linting errors in restapi.

This is a first step and only adds docstrings, etc. It doesn't refactor any
code.

Conflicts:
	prospector-more.yml
	readthedocs/restapi/views/model_views.py

* Reduce unused params.

In several cases, we can use the provided `request` rather than access `self`
(which could make these functions easier to test in isolation). In others, the
unused args could be folded into an unnamed kwarg param.

* Don't replace section variable.

This worked as intended, but only because the overridden section variable
would later evaluate to True. Using a different variable name makes this a bit
less error-prone.

* Minor docstring update

* Fix indent on docstring

* Punt on refactoring

* Fix call args

* Try unpinning testing reqs

* Bump up prospector higher level strictness

* Linting issues: arguments-differ, len-as-condition, redefined variables

* Remove unnecessary elses

This addresses no-else-return, which removes a `return` in an `else` after an
`if` that already has a `return`. This makes the default return more obvious in
most cases.

* Fix new linting issues with import order

Also, update travis and tox config for multiple versions of python

* Another fix on travis envs
2017-06-14 09:38:03 -07:00
Hank Gay 1d055ef724 Try to simplify the tox/travis interactions. 2017-06-05 10:52:14 -04:00
Hank Gay 0d73ebe7d6 Fix wonky syntax. 2017-06-01 15:29:17 -04:00
Hank Gay e46be8510b More Travis-CI tweakery. 2017-06-01 15:07:51 -04:00
Hank Gay 3b0c307079 Add Python 3.6 to tox.ini 2017-05-30 16:45:43 -04:00
CM Lubinski 9e07061730 Add eslint using the airbnb config. (#2905)
* Add eslint using the airbnb config.

In an effort to make the JS consistent, this adds an ESLint gulp task. ESLint
is *very* configurable, and has no defaults. Instead, this reaches for
airbnb's legacy config (which covers ES5), which is one of the most popular
configurations. As a last step, it turns off all of the rules which currently
fail. We can turn them on piecemeal, or override the airbnb style to use a
different format.

Rules to prioritize (as they likely indicate bugs):
* "array-callback-return": "off",
* "eqeqeq": "off",
* "guard-for-in": "off",
* "no-inner-declarations": "off",
* "no-loop-func": "off",
* "no-mixed-operators": "off",
* "no-undef": "off",
* "no-use-before-define": "off",
* "one-var": "off",

* Lint frontend in Travis.

This adds an ESLint step to the CI service so we prevent unlinted code from
making its way in.

* Create an ESLint tox env.

By adding a tox env for eslint, we allow users to run it locally as part of
tox runs.

Thanks for the suggestion @ericholscher!

* Fix tox call to gulp lint task
2017-05-24 16:12:33 -07:00
Frederick cbec8dda84 make tests parallelizable using pytest-xdist (#2899)
Be ware that running tests in parallel may cause tests to flake.
 This commit does not make parallel test the default it only makes it possible.
2017-05-24 13:46:40 -07:00
Daniel Pope db66b8ed32 Move pytest-cov dep to tox.ini 2017-05-23 11:26:23 -07:00
Daniel Pope 3aafd9785f Add tox target to generate coverage reports 2017-05-23 11:17:48 -07:00
Anthony Johnson 862d8a2c76
Add stricter linting to prospector as second pass 2017-03-21 11:39:00 -07:00
Berker Peksag 556a672781 Speed up build process (#2312)
* We don't need all dependecies to run 'tox -e lint'
* We don't really use pytest-django but it wouldn't hurt
  setting --reuse-db
* coveralls doesn't seem to be working at the moment so
  I removed it
* Delete unused runtests.sh. 'tox -e py27' already does
  the same job.
* Cache all dependencies in Travis CI
2016-07-18 11:31:37 -07:00
Eric Holscher 85a968fa46 Fix linting 2016-05-04 09:21:56 -07:00
Eric Holscher 21d6a8533a Fix pylint-django version 2015-12-03 15:05:55 -08:00
Anthony Johnson 09bcd4b57a Fix lint command in tox
Failing due to landscapeio/prospector#146 and when using pylint <1.5, it fails
with astroid 1.4
2015-11-30 14:28:02 -08:00
Eric Holscher 43a4baa4aa Clean up linting errors 2015-08-05 11:32:23 -07:00
Anthony Johnson f41e978e0e Add tox setting to disregard local_settings.py
If you use local_settings.py for development, tox will currently try to use
those settings. This disregards local_settings inside settings.test and friends
so that there is no chance for overlap.
2015-07-27 12:39:23 -07:00
Anthony Johnson 6704a52704 👋 python 2.6 2015-07-21 19:41:38 -07:00
Anthony Johnson be7bb6e5cf Update locale on testenv in tox 2015-07-21 19:41:38 -07:00
Anthony Johnson 525bd38ec6 More tox config 2015-07-21 19:41:37 -07:00
Anthony Johnson 18f68dee96 Add test of tox running test and lint commands, update travis 2015-07-21 19:41:37 -07:00