Skip to content

Commit

Permalink
chore: fix content type test failure (#1402)
Browse files Browse the repository at this point in the history
  • Loading branch information
NivedhaSenthil authored Mar 14, 2024
1 parent c93c2c0 commit 4d4da81
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 36 deletions.
75 changes: 40 additions & 35 deletions endpoints/getting-started/Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,68 +1,73 @@
GEM
remote: https://rubygems.org/
specs:
addressable (2.8.5)
addressable (2.8.6)
public_suffix (>= 2.0.2, < 6.0)
diff-lcs (1.5.0)
domain_name (0.5.20190701)
unf (>= 0.0.5, < 1.0.0)
faraday (2.7.10)
faraday-net_http (>= 2.0, < 3.1)
ruby2_keywords (>= 0.0.4)
faraday-net_http (3.0.2)
base64 (0.2.0)
diff-lcs (1.5.1)
domain_name (0.6.20240107)
faraday (2.9.0)
faraday-net_http (>= 2.0, < 3.2)
faraday-net_http (3.1.0)
net-http
http-accept (1.7.0)
http-cookie (1.0.5)
domain_name (~> 0.5)
json (2.6.3)
jwt (2.7.1)
mime-types (3.5.1)
json (2.7.1)
jwt (2.8.1)
base64
mime-types (3.5.2)
mime-types-data (~> 3.2015)
mime-types-data (3.2023.0808)
mime-types-data (3.2024.0305)
multi_json (1.15.0)
mustermann (3.0.0)
ruby2_keywords (~> 0.0.1)
net-http (0.4.1)
uri
netrc (0.11.0)
public_suffix (5.0.3)
rack (2.2.8)
rack-protection (3.1.0)
rack (~> 2.2, >= 2.2.4)
public_suffix (5.0.4)
rack (3.0.9.1)
rack-protection (4.0.0)
base64 (>= 0.1.0)
rack (>= 3.0.0, < 4)
rack-session (2.0.0)
rack (>= 3.0.0)
rack-test (2.1.0)
rack (>= 1.3)
rest-client (2.1.0)
http-accept (>= 1.7.0, < 2.0)
http-cookie (>= 1.0.2, < 2.0)
mime-types (>= 1.16, < 4.0)
netrc (~> 0.8)
rspec (3.12.0)
rspec-core (~> 3.12.0)
rspec-expectations (~> 3.12.0)
rspec-mocks (~> 3.12.0)
rspec-core (3.12.2)
rspec-support (~> 3.12.0)
rspec-expectations (3.12.3)
rspec (3.13.0)
rspec-core (~> 3.13.0)
rspec-expectations (~> 3.13.0)
rspec-mocks (~> 3.13.0)
rspec-core (3.13.0)
rspec-support (~> 3.13.0)
rspec-expectations (3.13.0)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.12.0)
rspec-mocks (3.12.6)
rspec-support (~> 3.13.0)
rspec-mocks (3.13.0)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.12.0)
rspec-support (3.12.1)
rspec-support (~> 3.13.0)
rspec-support (3.13.1)
rspec_junit_formatter (0.6.0)
rspec-core (>= 2, < 4, != 2.12.0)
ruby2_keywords (0.0.5)
signet (0.17.0)
signet (0.19.0)
addressable (~> 2.8)
faraday (>= 0.17.5, < 3.a)
jwt (>= 1.5, < 3.0)
multi_json (~> 1.10)
sinatra (3.1.0)
sinatra (4.0.0)
mustermann (~> 3.0)
rack (~> 2.2, >= 2.2.4)
rack-protection (= 3.1.0)
rack (>= 3.0.0, < 4)
rack-protection (= 4.0.0)
rack-session (>= 2.0.0, < 3)
tilt (~> 2.0)
tilt (2.2.0)
unf (0.1.4)
unf_ext
unf_ext (0.0.8.2)
tilt (2.3.0)
uri (0.13.0)

PLATFORMS
ruby
Expand Down
3 changes: 2 additions & 1 deletion endpoints/getting-started/spec/endpoint_sample_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
end

it "POST /echo renders message from request body" do
post "/echo", '{"message":"hello from test"}'
data = {"message" => "hello from test"}
post "/echo", data.to_json, "CONTENT_TYPE" => "application/json"

expect(last_response.status).to eq 200
expect(last_response.content_type).to eq "application/json"
Expand Down

0 comments on commit 4d4da81

Please sign in to comment.