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

[AF-29] Create actions for pause and unpause auctions #30

Merged
merged 2 commits into from
Mar 12, 2024
Merged

Conversation

ricardopacheco
Copy link
Owner

Issue number: resolves #29

Summary 🔴

This PR includes all the minimum resources necessary to pause and unpause an auction, whether at the database level or at the business rule level. The version 0.8.3 Changelog contains all the details.

Proposed / Possible solution 🔴

We create a specific contexts for the resources, and we follow all already established standards and conventions.

How to test 👮‍♂️

Start the related services, and open the console with the command bin/console. After that

Pause auction

attributes = {}

AuctionFunCore::Operations::AuctionContext::Processor::PauseOperation.call(attributes) do |result|
  result.success { |auction| puts auction.to_h }
  result.failure { |failure| puts failure.errors.to_h }
end

Unpause auction

attributes = {}

AuctionFunCore::Operations::AuctionContext::Processor::UnpauseOperation.call(attributes) do |result|
  result.success { |auction| puts auction.to_h }
  result.failure { |failure| puts failure.errors.to_h }
end

To simulate successful creation, change the hash of the attributes variable so that it meets all contract requirements.

Risks / Impacts 🔴

  • None anticipated

Requirements for deployment 🔴

  • None anticipated

@ricardopacheco ricardopacheco added type:feature A suggestion for general features status:in-review In Review status priority:high High priority labels Mar 12, 2024
@ricardopacheco ricardopacheco self-assigned this Mar 12, 2024
@ricardopacheco ricardopacheco merged commit a9a595e into main Mar 12, 2024
1 check passed
@ricardopacheco ricardopacheco deleted the AF-29 branch March 12, 2024 15:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority:high High priority status:in-review In Review status type:feature A suggestion for general features
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Set up auction pause/unpause
1 participant