From 1c7b4629240c49e02c482da6de1a6a2cc574304e Mon Sep 17 00:00:00 2001 From: tyler-ball Date: Wed, 24 Sep 2014 09:18:47 -0700 Subject: Trying to eradicate all traces of the JSON gem from Chef --- spec/unit/user_spec.rb | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'spec/unit/user_spec.rb') diff --git a/spec/unit/user_spec.rb b/spec/unit/user_spec.rb index 08bde33d7b..055512444b 100644 --- a/spec/unit/user_spec.rb +++ b/spec/unit/user_spec.rb @@ -154,6 +154,10 @@ describe Chef::User do it "does not include the password if not present" do @json.should_not include("password") end + + include_examples "to_json equalivent to Chef::JSONCompat.to_json" do + let(:subject) { @user } + end end describe "when deserializing from JSON" do @@ -163,7 +167,7 @@ describe Chef::User do "private_key" => "pandas", "password" => "password", "admin" => true } - @user = Chef::User.from_json(user.to_json) + @user = Chef::User.from_json(Chef::JSONCompat.to_json(user)) end it "should deserialize to a Chef::User object" do -- cgit v1.2.1