api_matchers 0.6.0 → 0.6.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/History.markdown +5 -0
- data/lib/api_matchers/headers/be_json.rb +4 -0
- data/lib/api_matchers/headers/be_xml.rb +4 -0
- data/lib/api_matchers/http_status_code/be_bad_request.rb +4 -0
- data/lib/api_matchers/http_status_code/be_internal_server_error.rb +4 -0
- data/lib/api_matchers/http_status_code/be_not_found.rb +4 -0
- data/lib/api_matchers/http_status_code/be_ok.rb +4 -0
- data/lib/api_matchers/http_status_code/be_unauthorized.rb +4 -0
- data/lib/api_matchers/http_status_code/be_unprocessable_entity.rb +4 -0
- data/lib/api_matchers/http_status_code/create_resource.rb +4 -0
- data/lib/api_matchers/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5898931ec179ab8dd81ed8552603cb2b8af12579
|
4
|
+
data.tar.gz: bf28c99233720e3051d57ddf4b877720439214a4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 51c74fc5d3cd98e4d9b94a72c5c2301f1abed5bab16173eb20332b31f723ad206a4e95eb28931fcf6e260fa9b6d91d8d2cc09dbab35774363af8f958fc64ca48
|
7
|
+
data.tar.gz: 6c13e7610d754784d6e5d7ea21223cf52c54103d5e09fad374779a3366d2a5e3cb1d0d2a3a902fcfcd3aac086ec1c581d90a0f6ad6de56060774d6f49faaaad6
|
data/History.markdown
CHANGED
@@ -13,6 +13,10 @@ module APIMatchers
|
|
13
13
|
%Q{expected to not be a JSON response. Got: '#{expected_content_type}'.}
|
14
14
|
end
|
15
15
|
|
16
|
+
def description
|
17
|
+
"be in JSON"
|
18
|
+
end
|
19
|
+
|
16
20
|
# RSpec 2 compatibility:
|
17
21
|
alias_method :failure_message_for_should, :failure_message
|
18
22
|
alias_method :failure_message_for_should_not, :failure_message_when_negated
|
@@ -13,6 +13,10 @@ module APIMatchers
|
|
13
13
|
%Q{expected to not be a XML response. Got: '#{expected_content_type}'.}
|
14
14
|
end
|
15
15
|
|
16
|
+
def description
|
17
|
+
"be in XML"
|
18
|
+
end
|
19
|
+
|
16
20
|
# RSpec 2 compatibility:
|
17
21
|
alias_method :failure_message_for_should, :failure_message
|
18
22
|
alias_method :failure_message_for_should_not, :failure_message_when_negated
|
@@ -13,6 +13,10 @@ module APIMatchers
|
|
13
13
|
%Q{expected that '#{@http_status_code}' to NOT be a Bad Request with the status '400'.}
|
14
14
|
end
|
15
15
|
|
16
|
+
def description
|
17
|
+
"be a Bad Request with the status '400'"
|
18
|
+
end
|
19
|
+
|
16
20
|
# RSpec 2 compatibility:
|
17
21
|
alias_method :failure_message_for_should, :failure_message
|
18
22
|
alias_method :failure_message_for_should_not, :failure_message_when_negated
|
@@ -13,6 +13,10 @@ module APIMatchers
|
|
13
13
|
%Q{expected that '#{@http_status_code}' to NOT be Internal Server Error.}
|
14
14
|
end
|
15
15
|
|
16
|
+
def description
|
17
|
+
"be Internal Server Error with the status '500'"
|
18
|
+
end
|
19
|
+
|
16
20
|
# RSpec 2 compatibility:
|
17
21
|
alias_method :failure_message_for_should, :failure_message
|
18
22
|
alias_method :failure_message_for_should_not, :failure_message_when_negated
|
@@ -13,6 +13,10 @@ module APIMatchers
|
|
13
13
|
%Q{expected that '#{@http_status_code}' to NOT be Not Found with the status '404'.}
|
14
14
|
end
|
15
15
|
|
16
|
+
def description
|
17
|
+
"be Not Found with the status '404'"
|
18
|
+
end
|
19
|
+
|
16
20
|
# RSpec 2 compatibility:
|
17
21
|
alias_method :failure_message_for_should, :failure_message
|
18
22
|
alias_method :failure_message_for_should_not, :failure_message_when_negated
|
@@ -13,6 +13,10 @@ module APIMatchers
|
|
13
13
|
%Q{expected that '#{@http_status_code}' to NOT be ok with the status '200'.}
|
14
14
|
end
|
15
15
|
|
16
|
+
def description
|
17
|
+
"be ok with the status '200'"
|
18
|
+
end
|
19
|
+
|
16
20
|
# RSpec 2 compatibility:
|
17
21
|
alias_method :failure_message_for_should, :failure_message
|
18
22
|
alias_method :failure_message_for_should_not, :failure_message_when_negated
|
@@ -13,6 +13,10 @@ module APIMatchers
|
|
13
13
|
%Q{expected that '#{@http_status_code}' to NOT be Unauthorized.}
|
14
14
|
end
|
15
15
|
|
16
|
+
def description
|
17
|
+
"be Unauthorized with the status '401'"
|
18
|
+
end
|
19
|
+
|
16
20
|
# RSpec 2 compatibility:
|
17
21
|
alias_method :failure_message_for_should, :failure_message
|
18
22
|
alias_method :failure_message_for_should_not, :failure_message_when_negated
|
@@ -13,6 +13,10 @@ module APIMatchers
|
|
13
13
|
%Q{expected that '#{@http_status_code}' to NOT be Unprocessable entity with the status '#{expected_status_code}'.}
|
14
14
|
end
|
15
15
|
|
16
|
+
def description
|
17
|
+
"be Unprocessable entity with the status '422'"
|
18
|
+
end
|
19
|
+
|
16
20
|
# RSpec 2 compatibility:
|
17
21
|
alias_method :failure_message_for_should, :failure_message
|
18
22
|
alias_method :failure_message_for_should_not, :failure_message_when_negated
|
@@ -13,6 +13,10 @@ module APIMatchers
|
|
13
13
|
%Q{expected that '#{@http_status_code}' to NOT be Created Resource.}
|
14
14
|
end
|
15
15
|
|
16
|
+
def description
|
17
|
+
"be Created Resource with the status '201'"
|
18
|
+
end
|
19
|
+
|
16
20
|
# RSpec 2 compatibility:
|
17
21
|
alias_method :failure_message_for_should, :failure_message
|
18
22
|
alias_method :failure_message_for_should_not, :failure_message_when_negated
|
data/lib/api_matchers/version.rb
CHANGED