Skip to content

Commit

Permalink
Quiet down resource specs.
Browse files Browse the repository at this point in the history
  • Loading branch information
tpendragon committed Dec 3, 2018
1 parent cc1e77e commit 28be265
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions lib/valkyrie/specs/shared_specs/resource.rb
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,6 @@ class MyCustomResource < Valkyrie::Resource
resource.other_property = "test"

expect(resource["other_property"]).to eq ["test"]
expect { resource["other_property"] }.to output(/\[DEPRECATION\]/).to_stderr
resource_klass.schema.delete(:other_property)
end
end
Expand Down Expand Up @@ -121,8 +120,8 @@ class MyCustomResource < Valkyrie::Resource
it "can set values with string properties, but will throw a deprecation error" do
resource_klass.attribute :string_property

resource = resource_klass.new("string_property" => "bla")
expect { resource_klass.new("string_property" => "bla") }.to output(/\[DEPRECATION\]/).to_stderr
resource = nil
expect { resource = resource_klass.new("string_property" => "bla") }.to output(/\[DEPRECATION\]/).to_stderr

expect(resource.string_property).to eq ["bla"]
resource_klass.schema.delete(:string_property)
Expand Down

0 comments on commit 28be265

Please sign in to comment.