Created
July 3, 2020 14:47
-
-
Save NilsonLima/760bae65c8a912ca2bfc1f49e035f0d0 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
require "test_helper" | |
class Smartphone::Contract::CancelTest < ActiveSupport::TestCase | |
setup do | |
@smartphone_contract = smartphone_contracts(:base_contract) | |
@params = { id: @smartphone_contract[:id], ... } | |
end | |
subject { Smartphone::Contract::Cancel } | |
context "uncancelable" do | |
should "fail" do | |
# | |
end | |
end | |
context "cancelable" do | |
context "not suspendable" do | |
should "fail" do | |
# | |
end | |
end | |
context "suspendable" do | |
context "can't cancel certficate" do | |
context "happy path" do | |
should "return success" do | |
# | |
end | |
end | |
end | |
context "can cancel certificate" do | |
context "locally uncancelable" do | |
should "fail" do | |
# | |
end | |
end | |
context "locally cancelable" do | |
context "happy path" do | |
should "return success" do | |
# | |
end | |
end | |
end | |
end | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment