From 7ea5521dc2061fd7e72816b393b54f862eb2b31d Mon Sep 17 00:00:00 2001 From: "Darren L. Weber, Ph.D" Date: Thu, 27 Oct 2016 16:01:43 -0700 Subject: [PATCH] Use iso8601 time format in rspec expectation --- spec/support/examples/a_create_endpoint.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spec/support/examples/a_create_endpoint.rb b/spec/support/examples/a_create_endpoint.rb index 68ca66da..bf58d9ed 100644 --- a/spec/support/examples/a_create_endpoint.rb +++ b/spec/support/examples/a_create_endpoint.rb @@ -87,7 +87,7 @@ def body_from_instance(instance, extra_params) end it "assigns the correct object to @#{factory.to_s}" do expect(assigns(factory)).to be_a model_class - expect(assigns(factory).created_at.to_formatted_s(:dpn)).to eql(valid_post_body[:created_at]) + expect(assigns(factory).created_at.iso8601).to eql(valid_post_body[:created_at]) end it "renders json" do expect(response.content_type).to eql("application/json")