-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
[spaceship] Check if app removed from sale #21902
Open
lucgrabowski
wants to merge
18
commits into
master
Choose a base branch
from
lucgrabowski-check-if-app-removed-from-sale
base: master
Could not load branches
Branch not found: {{ refName }}
Could not load tags
Nothing to show
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 16 commits
Commits
Show all changes
18 commits
Select commit
Hold shift + click to select a range
814d92a
Move endpoint version v1 from hostname to path to define it per reque…
lucgrabowski cb08060
Fix client tests
lucgrabowski 9a453dd
Fix middleware tests and change services order in array to first matc…
lucgrabowski d21f455
Add first v2 request to get app availabilities
lucgrabowski 85e29e3
require model files
lucgrabowski a4147f0
Add ContentStatus enum values
lucgrabowski cb668a8
Return first app availability from models array
lucgrabowski 1a88bd4
Add a helper to check if app is removed from sale (ready for distribu…
lucgrabowski 039d68a
Remove commas, run rubocop
lucgrabowski 8a70049
Merge branch 'lucgrabowski-add-get-app-availabilities-v2-request' int…
lucgrabowski 5b97069
Run rubocop
lucgrabowski 7333e81
Add tests tor App's get_app_availabilities
lucgrabowski b75e6c3
Merge branch 'lucgrabowski-add-get-app-availabilities-v2-request' int…
lucgrabowski c969132
Add tests to check if app is removed_from_sale?
lucgrabowski 7ed5fd4
Fixture update
lucgrabowski d924281
Mark app as removed from sale when there is no ready for distribution…
lucgrabowski 6fe8395
Merge branch 'master' into lucgrabowski-check-if-app-removed-from-sale
lucgrabowski eb47fd4
Fix merge
lucgrabowski File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
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
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
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
23 changes: 23 additions & 0 deletions
23
spaceship/lib/spaceship/connect_api/models/app_availability.rb
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
require_relative '../model' | ||
module Spaceship | ||
class ConnectAPI | ||
class AppAvailability | ||
include Spaceship::ConnectAPI::Model | ||
|
||
attr_accessor :app | ||
attr_accessor :available_in_new_territories | ||
|
||
attr_accessor :territoryAvailabilities | ||
|
||
attr_mapping({ | ||
app: 'app', | ||
availableInNewTerritories: 'available_in_new_territories', | ||
territoryAvailabilities: 'territory_availabilities' | ||
}) | ||
|
||
def self.type | ||
return 'appAvailabilities' | ||
end | ||
end | ||
end | ||
end |
62 changes: 62 additions & 0 deletions
62
spaceship/lib/spaceship/connect_api/models/territory_availability.rb
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
require_relative '../model' | ||
module Spaceship | ||
class ConnectAPI | ||
class TerritoryAvailability | ||
include Spaceship::ConnectAPI::Model | ||
|
||
attr_accessor :available | ||
attr_accessor :content_statuses | ||
attr_accessor :pre_order_enabled | ||
attr_accessor :pre_order_publish_date | ||
attr_accessor :release_date | ||
|
||
module ContentStatus | ||
AVAILABLE = "AVAILABLE" | ||
AVAILABLE_FOR_PREORDER_ON_DATE = "AVAILABLE_FOR_PREORDER_ON_DATE" | ||
PROCESSING_TO_NOT_AVAILABLE = "PROCESSING_TO_NOT_AVAILABLE" | ||
PROCESSING_TO_AVAILABLE = "PROCESSING_TO_AVAILABLE" | ||
PROCESSING_TO_PRE_ORDER = "PROCESSING_TO_PRE_ORDER" | ||
AVAILABLE_FOR_SALE_UNRELEASED_APP = "AVAILABLE_FOR_SALE_UNRELEASED_APP" | ||
PREORDER_ON_UNRELEASED_APP = "PREORDER_ON_UNRELEASED_APP" | ||
AVAILABLE_FOR_PREORDER = "AVAILABLE_FOR_PREORDER" | ||
MISSING_RATING = "MISSING_RATING" | ||
CANNOT_SELL_RESTRICTED_RATING = "CANNOT_SELL_RESTRICTED_RATING" | ||
BRAZIL_REQUIRED_TAX_ID = "BRAZIL_REQUIRED_TAX_ID" | ||
MISSING_GRN = "MISSING_GRN" | ||
UNVERIFIED_GRN = "UNVERIFIED_GRN" | ||
CANNOT_SELL_SEVENTEEN_PLUS_APPS = "CANNOT_SELL_SEVENTEEN_PLUS_APPS" | ||
CANNOT_SELL_SEXUALLY_EXPLICIT = "CANNOT_SELL_SEXUALLY_EXPLICIT" | ||
CANNOT_SELL_NON_IOS_GAMES = "CANNOT_SELL_NON_IOS_GAMES" | ||
CANNOT_SELL_SEVENTEEN_PLUS_GAMES = "CANNOT_SELL_SEVENTEEN_PLUS_GAMES" | ||
CANNOT_SELL_FREQUENT_INTENSE_GAMBLING = "CANNOT_SELL_FREQUENT_INTENSE_GAMBLING" | ||
CANNOT_SELL_CASINO = "CANNOT_SELL_CASINO" | ||
CANNOT_SELL_CASINO_WITHOUT_GRAC = "CANNOT_SELL_CASINO_WITHOUT_GRAC" | ||
CANNOT_SELL_CASINO_WITHOUT_AGE_VERIFICATION = "CANNOT_SELL_CASINO_WITHOUT_AGE_VERIFICATION" | ||
CANNOT_SELL_FREQUENT_INTENSE_ALCOHOL_TOBACCO_DRUGS = "CANNOT_SELL_FREQUENT_INTENSE_ALCOHOL_TOBACCO_DRUGS" | ||
CANNOT_SELL_FREQUENT_INTENSE_VIOLENCE = "CANNOT_SELL_FREQUENT_INTENSE_VIOLENCE" | ||
CANNOT_SELL_FREQUENT_INTENSE_SEXUAL_CONTENT_NUDITY = "CANNOT_SELL_FREQUENT_INTENSE_SEXUAL_CONTENT_NUDITY" | ||
CANNOT_SELL_INFREQUENT_MILD_ALCOHOL_TOBACCO_DRUGS = "CANNOT_SELL_INFREQUENT_MILD_ALCOHOL_TOBACCO_DRUGS" | ||
CANNOT_SELL_INFREQUENT_MILD_SEXUAL_CONTENT_NUDITY = "CANNOT_SELL_INFREQUENT_MILD_SEXUAL_CONTENT_NUDITY" | ||
CANNOT_SELL_ADULT_ONLY = "CANNOT_SELL_ADULT_ONLY" | ||
CANNOT_SELL_FREQUENT_INTENSE = "CANNOT_SELL_FREQUENT_INTENSE" | ||
CANNOT_SELL_FREQUENT_INTENSE_WITHOUT_GRAC = "CANNOT_SELL_FREQUENT_INTENSE_WITHOUT_GRAC" | ||
CANNOT_SELL_GAMBLING_CONTESTS = "CANNOT_SELL_GAMBLING_CONTESTS" | ||
CANNOT_SELL_GAMBLING = "CANNOT_SELL_GAMBLING" | ||
CANNOT_SELL_CONTESTS = "CANNOT_SELL_CONTESTS" | ||
CANNOT_SELL = "CANNOT_SELL" | ||
end | ||
|
||
attr_mapping({ | ||
available: 'available', | ||
contentStatuses: 'content_statuses', | ||
preOrderEnabled: 'pre_order_enabled', | ||
preOrderPublishDate: 'pre_order_publish_date', | ||
releaseDate: 'release_date' | ||
}) | ||
|
||
def self.type | ||
return 'territoryAvailabilities' | ||
end | ||
end | ||
end | ||
end |
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
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
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
Oops, something went wrong.
Oops, something went wrong.
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.
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.
I'm wondering if it shouldn't be renamed to
removed_from_sale_or_not_ready?