Skip to content

Jonahstanley/acceptance tests unique database - #298

Merged
JonahStanley merged 10 commits into
masterfrom
jonahstanley/acceptance-tests-unique-database
Jul 10, 2013
Merged

Jonahstanley/acceptance tests unique database#298
JonahStanley merged 10 commits into
masterfrom
jonahstanley/acceptance-tests-unique-database

Conversation

@JonahStanley

Copy link
Copy Markdown
Contributor

Suggested Reviewers: @jzoldak @wedaly
Acceptance tests now pull from their own database/collection
These are destroyed at the end of each scenario

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

These lines need comments. Specifically, why are we dropping the database in one case (the content store) but dropping collections in the other (the module store)?

@jzoldak

jzoldak commented Jul 1, 2013

Copy link
Copy Markdown
Contributor

@JonahStanley the modulestore collection is not being cleared out after the last test is run. To verify:
from mongo

use test_xmodule
db.dropDatabase()

run the tests, then from mongo

use test_xmodule
show collections

4 collections are created by running rake test_acceptance_lms.

JonahStanley added 8 commits July 9, 2013 08:54
These databases/collections are cleared after harvest
This might allow parallel features in the future
This is to allow acceptance tests to properly link and know the names of its other parts
Acceptance_static is used to prevent collect static from using a seed
test.py had its seed removed due to redundancy
Comment thread rakelib/tests.rake Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Add in a comment explaining why we did this, so that we remember and other people know why too.

This explains why acceptance_static is used

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Explain why we need to do this. Something like that we want the same settings as acceptance.py except for the db or collection names, because otherwise any call to django-admin (including collectstatic) will create another uniquely named one.

@jzoldak

jzoldak commented Jul 10, 2013

Copy link
Copy Markdown
Contributor

👍

JonahStanley pushed a commit that referenced this pull request Jul 10, 2013
…-database

Jonahstanley/acceptance tests unique database
@JonahStanley
JonahStanley merged commit 786f422 into master Jul 10, 2013
@JonahStanley
JonahStanley deleted the jonahstanley/acceptance-tests-unique-database branch July 10, 2013 21:09
e-kolpakov referenced this pull request in open-craft/openedx-platform Nov 3, 2014
…roficiency-avg

ziafazal/api-fix-company-proficiency-avg: fix for incorrect average calculation
CrewS pushed a commit to CrewS/edx-platform-1 that referenced this pull request Feb 18, 2019
Sujeet1379 pushed a commit to chandrudev/edx-platform that referenced this pull request Nov 17, 2022
* Commits:
  Run coverage via Github Action
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