This repository has been archived by the owner on Mar 15, 2018. It is now read-only.
Migrate free apps without world AER (bug 916853) #1146
Merged
muffinresearch
merged 1 commit into
mozilla:master
from
muffinresearch:cmd-migrate-free-apps-without-world-aer-916853
Sep 27, 2013
Merged
Migrate free apps without world AER (bug 916853) #1146
muffinresearch
merged 1 commit into
mozilla:master
from
muffinresearch:cmd-migrate-free-apps-without-world-aer-916853
Sep 27, 2013
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
|
||
|
||
class Command(NoArgsCommand): | ||
help = "Migrate free apps without a world AER to enable_new_regions=True." |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
single quotes
@cvan, @diox, @robhudson, @andymckay: Any further comments? |
and the code that determines when to check/uncheck the box - that gets changed in some other PR, I presume? |
r+wc |
self.webapp.update(premium_type=amo.ADDON_PREMIUM) | ||
eq_(self.webapp.enable_new_regions, False) | ||
eq_(len(AER.objects.filter(addon=self.webapp, | ||
region=WORLDWIDE.id)), 0) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
eq_(not AER.objects.filter(addon=self.webapp, region=WORLDWIDE.id).exists())
maybe
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
eq_(self.webapp.addonexcludedregion.filter(region=WORLDWIDE.id).count(), 0)
r+wc |
Cmd to migrate free apps to enable_new_regions (bug 916853)
muffinresearch
added a commit
that referenced
this pull request
Sep 27, 2013
…thout-world-aer-916853 Migrate free apps without world AER (bug 916853)
muffinresearch
deleted the
cmd-migrate-free-apps-without-world-aer-916853
branch
September 27, 2013 20:04
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Adds a management command to migrate free apps without a worldwide AddonExcludedRegion (AER) record to have enable_new_regions=True (bug 916853)