Skip to content
This repository has been archived by the owner on Feb 27, 2019. It is now read-only.

Fix test errors #61

Merged
merged 1 commit into from
Nov 21, 2014
Merged

Fix test errors #61

merged 1 commit into from
Nov 21, 2014

Conversation

kyoshino
Copy link
Contributor

The tests passed locally with the tox command.

@@ -30,10 +30,12 @@

DATABASE_ROUTERS = ('multidb.PinningMasterSlaveRouter',)

SITE_URL = ''

Choose a reason for hiding this comment

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

Apparently this is just for tests here. It's been removed as a thing from playdoh apparently. Maybe just mock this one too?

Choose a reason for hiding this comment

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

Best would be if we could remove the need for that setting from tests here, but I've not looked at how hard that would be.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

If I remove this, the tests fail somehow even when there are @patch.object(settings, 'SITE_URL', 'http://testserver').

Choose a reason for hiding this comment

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

Can you try to add it to the local.py when that file is written in tests/__init__.py then?

Choose a reason for hiding this comment

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

I'm trying to keep this out because I remember other tools would use it if it existed. Not sure if those libs still exist, but this does have breakage potential if I'm remembering correctly.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Adding SITE_URL = '' to .playdoh/funtestapp/project/settings/local.py-dist solved the issue. Will send a separate PR for that.

@pmclanahan
Copy link

I wouldn't do that in Playdoh either. What I'm saying is that the funfactory test suite is already modifying that local.py as part of tests setup. Just add the settings programmatically there and the suite should pass.

@kyoshino
Copy link
Contributor Author

I got it. I could just add one line in tests/__init__.py.

@kyoshino
Copy link
Contributor Author

The all tests passed.

@pmclanahan
Copy link

Nice! Works for me. Thanks @kyoshino 🍰

pmclanahan pushed a commit that referenced this pull request Nov 21, 2014
@pmclanahan pmclanahan merged commit 7695912 into mozilla:master Nov 21, 2014
@kyoshino kyoshino deleted the fix-tests branch November 21, 2014 05:36
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants