Created
November 9, 2021 03:13
-
-
Save elias19r/f02ccdc852a97d76c227ff480ed747dd to your computer and use it in GitHub Desktop.
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
describe "setting an attribute with value from a parameter" do | |
context "when parameter key is not present" do | |
it "does not assume any value for the attribute" | |
it "does not set the attribute" | |
end | |
context "when parameter key is present" do | |
context "when parameter value is not blank" do | |
it "sets value to the attribute" | |
end | |
context "when parameter value is blank" do | |
context "when attribute is primary key" do | |
it "sets the attribute to nil" | |
end | |
context "when attribute is not primary key but it allows nil" do | |
it "sets the attribute to nil" | |
end | |
context "when attribute is not primary key and it does not allow nil" do | |
it "assumes an empty value for the attribute" | |
it "sets that empty value to the attribute" | |
end | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment