Skip to content
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

Fix all the test failures #4387

Closed
benjaoming opened this issue Sep 7, 2015 · 11 comments
Closed

Fix all the test failures #4387

benjaoming opened this issue Sep 7, 2015 · 11 comments
Assignees
Labels

Comments

@benjaoming
Copy link
Contributor

Circle CI support has been added to 0.14.x so we can start sorting out the failing tests. I'm not quite convinced that we should be shipping the next 0.14 patch release without having fixed all the tests.
#4385 fixes some of them... once it's merged, it'd be great if someone could fix the areas under their domain / expertise. For instance, Someone Else (TM) should fix the compressor stuff.

You will see in the PR that there are a substantial amount of fixes that could cause problems down the road. Because of limited time this week, I can't fix more than what I'm doing in #4385.

@benjaoming
Copy link
Contributor Author

@rtibbles BDD tests are passing now, but there are a lot of issues due to compress not being run -- either we use COMPRESS_OFFLINE = True during tests or we somehow create the compressed files before testing (my initial attempt didn't work).

Would you mind taking a look at the compress stuff after #4385 is merged?

@aronasorman
Copy link
Collaborator

I think we should place the 0.14.x branch on critical bugfix mode -- 0.15 is ~4 weeks away, and splitting our time on getting tests fixed on 0.14 will take away time from getting 0.15 as stable as possible (which already has passing tests).

@benjaoming
Copy link
Contributor Author

@aronasorman please look at #4385 before making a judgement.

@benjaoming
Copy link
Contributor Author

@rtibbles nevermind, I found a way to switch on compression in the tests: 03fdc9d

@rtibbles
Copy link
Member

rtibbles commented Sep 7, 2015

The problem with trying to run the server in actual production mode (i.e. creating the compressed files before we do any tests) is that Django < 1.7 uses the staticfiles app to serve static files during tests. So, any files that get compiled into the static files folder (such as Django Compressor and Django JS Reverse files) don't actually get served during testing.

This is really bad from a testing point of view, especially as we move towards more built front end assets, as it means that our testing environment is divergent from our production environment. I would like to recommend upgrading to at least Django 1.7 to deal with this ASAP.

@benjaoming
Copy link
Contributor Author

@rtibbles this is just a hindsight attempt to get tests working for the next 0.14.1 release.

@rtibbles
Copy link
Member

rtibbles commented Sep 7, 2015

Does the override_settings decorator not work on a whole test suite, btw? I feel like I have tried it before also, and have then just done something completely different to avoid dynamically altering the settings object directly.

@rtibbles
Copy link
Member

rtibbles commented Sep 7, 2015

I am also wary of these test modifications as, presumably, these would eventually get merged back into develop where these tests were working (until a merge from 0.14.x broke them - but they should be fixed again shortly).

@benjaoming
Copy link
Contributor Author

@rtibbles I think override_settings is supposed to be used on an individual test case, it only affects what happens in the test, but that can still spill over as certain environments may not be entirely isolated.

@aronasorman
Copy link
Collaborator

I believe the general consensus was to extensively test 0.14.x manually. With 0.15 so close to release (~2 weeks), no need to pour more resources into 0.14 any more than the bare minimum.

@benjaoming
Copy link
Contributor Author

Yeah it's fine, I managed to fix tests in a recently discarded PR and run them locally. Didn't find anything suspicious. See #4385

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants