code42_api_rails 0.0.2 → 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/features/api_response.feature +2 -2
- data/lib/code42_api/railtie.rb +1 -0
- data/lib/code42_api/version.rb +1 -1
- data/test/code42_api_test.rb +1 -1
- data/test/dummy/log/test.log +103 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 704dada6a51c3c64ea95a90b4173d06a020794af
|
4
|
+
data.tar.gz: a90e15ea6b2bbce64683b9fc92bd336d6787790d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 765565d82032bea8997e89753828159079babc89b1186b875735a8b81467a1a22efb269eddd5cd098949d649a22ce171909bad3fbd544118f04ead2184aa4f94
|
7
|
+
data.tar.gz: 54ce81d2b1ba84053762c6c963bc72c55fe1627574012585693896830892a91cdd29dcfa6b9b2c82e4be083cf084dd27701e769addac97805467b837ba404afa
|
@@ -16,7 +16,7 @@ Feature: API Response
|
|
16
16
|
"id": 3,
|
17
17
|
"first_name": "Stephen",
|
18
18
|
"last_name": "Colbert",
|
19
|
-
"created_at": "2014-01-01T06:00:
|
20
|
-
"updated_at": "2014-01-01T06:00:
|
19
|
+
"created_at": "2014-01-01T06:00:00Z",
|
20
|
+
"updated_at": "2014-01-01T06:00:00Z"
|
21
21
|
}
|
22
22
|
"""
|
data/lib/code42_api/railtie.rb
CHANGED
data/lib/code42_api/version.rb
CHANGED
data/test/code42_api_test.rb
CHANGED
@@ -3,6 +3,6 @@ require 'test_helper'
|
|
3
3
|
class Code42ApiTest < ActiveSupport::TestCase
|
4
4
|
test "time as json returns a iso8601 string" do
|
5
5
|
time = Time.utc(2014,1,1,12,0,0).in_time_zone
|
6
|
-
assert_equal "2014-01-01T12:00:
|
6
|
+
assert_equal "2014-01-01T12:00:00Z", time.as_json
|
7
7
|
end
|
8
8
|
end
|
data/test/dummy/log/test.log
CHANGED
@@ -1817,6 +1817,109 @@ Completed 200 OK in 0ms (Views: 0.0ms | ActiveRecord: 0.0ms)
|
|
1817
1817
|
[1m[35mSQL (0.0ms)[0m INSERT INTO "authors" ("created_at", "first_name", "id", "last_name", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-01-01 06:00:00.000000"], ["first_name", "Stephen"], ["id", 3], ["last_name", "King"], ["updated_at", "2014-01-01 06:00:00.000000"]]
|
1818
1818
|
[1m[36m (0.0ms)[0m [1mRELEASE SAVEPOINT active_record_1[0m
|
1819
1819
|
Started PUT "/authors/3" for 127.0.0.1 at 2014-01-01 06:00:00 UTC
|
1820
|
+
Processing by AuthorsController#update as JSON
|
1821
|
+
Parameters: {"author"=>{"last_name"=>nil}, "id"=>"3"}
|
1822
|
+
[1m[35mAuthor Load (0.0ms)[0m SELECT "authors".* FROM "authors" WHERE "authors"."id" = ? LIMIT 1 [["id", 3]]
|
1823
|
+
[1m[36m (0.0ms)[0m [1mSAVEPOINT active_record_1[0m
|
1824
|
+
[1m[35m (0.0ms)[0m ROLLBACK TO SAVEPOINT active_record_1
|
1825
|
+
Completed 422 Unprocessable Entity in 0ms (Views: 0.0ms | ActiveRecord: 0.0ms)
|
1826
|
+
[1m[36m (0.5ms)[0m [1mrollback transaction[0m
|
1827
|
+
[1m[36m (0.1ms)[0m [1mbegin transaction[0m
|
1828
|
+
---------------------------------------------------------
|
1829
|
+
Code42ApiTest: test_time_as_json_returns_a_iso8601_string
|
1830
|
+
---------------------------------------------------------
|
1831
|
+
[1m[35m (0.1ms)[0m rollback transaction
|
1832
|
+
[1m[36m (0.1ms)[0m [1mbegin transaction[0m
|
1833
|
+
------------------------
|
1834
|
+
ErrorsTest: test_as_json
|
1835
|
+
------------------------
|
1836
|
+
[1m[35m (0.1ms)[0m rollback transaction
|
1837
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
1838
|
+
---------------------------
|
1839
|
+
ErrorsTest: test_error_type
|
1840
|
+
---------------------------
|
1841
|
+
[1m[35m (0.1ms)[0m rollback transaction
|
1842
|
+
[1m[36m (0.1ms)[0m [1mbegin transaction[0m
|
1843
|
+
---------------------------------------------------------
|
1844
|
+
Code42ApiTest: test_time_as_json_returns_a_iso8601_string
|
1845
|
+
---------------------------------------------------------
|
1846
|
+
[1m[35m (0.0ms)[0m rollback transaction
|
1847
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
1848
|
+
------------------------
|
1849
|
+
ErrorsTest: test_as_json
|
1850
|
+
------------------------
|
1851
|
+
[1m[35m (0.1ms)[0m rollback transaction
|
1852
|
+
[1m[36m (0.1ms)[0m [1mbegin transaction[0m
|
1853
|
+
---------------------------
|
1854
|
+
ErrorsTest: test_error_type
|
1855
|
+
---------------------------
|
1856
|
+
[1m[35m (0.0ms)[0m rollback transaction
|
1857
|
+
[1m[36m (0.1ms)[0m [1mbegin transaction[0m
|
1858
|
+
[1m[35m (0.1ms)[0m commit transaction
|
1859
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
1860
|
+
[1m[35m (0.0ms)[0m SAVEPOINT active_record_1
|
1861
|
+
[1m[36mSQL (0.0ms)[0m [1mINSERT INTO "authors" ("created_at", "first_name", "id", "last_name", "updated_at") VALUES (?, ?, ?, ?, ?)[0m [["created_at", "2014-01-01 06:00:00.000000"], ["first_name", "Stephen"], ["id", 3], ["last_name", "King"], ["updated_at", "2014-01-01 06:00:00.000000"]]
|
1862
|
+
[1m[35m (0.0ms)[0m RELEASE SAVEPOINT active_record_1
|
1863
|
+
Started PUT "/authors/3" for 127.0.0.1 at 2014-01-01 06:00:00 UTC
|
1864
|
+
Processing by AuthorsController#update as JSON
|
1865
|
+
Parameters: {"author"=>{"last_name"=>"Colbert"}, "id"=>"3"}
|
1866
|
+
[1m[36mAuthor Load (0.0ms)[0m [1mSELECT "authors".* FROM "authors" WHERE "authors"."id" = ? LIMIT 1[0m [["id", 3]]
|
1867
|
+
[1m[35m (0.0ms)[0m SAVEPOINT active_record_1
|
1868
|
+
[1m[36mSQL (0.0ms)[0m [1mUPDATE "authors" SET "last_name" = ? WHERE "authors"."id" = 3[0m [["last_name", "Colbert"]]
|
1869
|
+
[1m[35m (0.0ms)[0m RELEASE SAVEPOINT active_record_1
|
1870
|
+
Completed 200 OK in 0ms (Views: 0.0ms | ActiveRecord: 0.0ms)
|
1871
|
+
[1m[36m (0.5ms)[0m [1mrollback transaction[0m
|
1872
|
+
[1m[35m (0.1ms)[0m begin transaction
|
1873
|
+
[1m[36m (0.0ms)[0m [1mcommit transaction[0m
|
1874
|
+
[1m[35m (0.1ms)[0m begin transaction
|
1875
|
+
[1m[36m (0.0ms)[0m [1mSAVEPOINT active_record_1[0m
|
1876
|
+
[1m[35mSQL (0.0ms)[0m INSERT INTO "authors" ("created_at", "first_name", "id", "last_name", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-01-01 06:00:00.000000"], ["first_name", "Stephen"], ["id", 3], ["last_name", "King"], ["updated_at", "2014-01-01 06:00:00.000000"]]
|
1877
|
+
[1m[36m (0.0ms)[0m [1mRELEASE SAVEPOINT active_record_1[0m
|
1878
|
+
Started PUT "/authors/3" for 127.0.0.1 at 2014-01-01 06:00:00 UTC
|
1879
|
+
Processing by AuthorsController#update as JSON
|
1880
|
+
Parameters: {"author"=>{"last_name"=>nil}, "id"=>"3"}
|
1881
|
+
[1m[35mAuthor Load (0.0ms)[0m SELECT "authors".* FROM "authors" WHERE "authors"."id" = ? LIMIT 1 [["id", 3]]
|
1882
|
+
[1m[36m (0.0ms)[0m [1mSAVEPOINT active_record_1[0m
|
1883
|
+
[1m[35m (0.0ms)[0m ROLLBACK TO SAVEPOINT active_record_1
|
1884
|
+
Completed 422 Unprocessable Entity in 0ms (Views: 0.0ms | ActiveRecord: 0.0ms)
|
1885
|
+
[1m[36m (0.4ms)[0m [1mrollback transaction[0m
|
1886
|
+
[1m[36m (0.1ms)[0m [1mbegin transaction[0m
|
1887
|
+
------------------------
|
1888
|
+
ErrorsTest: test_as_json
|
1889
|
+
------------------------
|
1890
|
+
[1m[35m (0.1ms)[0m rollback transaction
|
1891
|
+
[1m[36m (0.1ms)[0m [1mbegin transaction[0m
|
1892
|
+
---------------------------
|
1893
|
+
ErrorsTest: test_error_type
|
1894
|
+
---------------------------
|
1895
|
+
[1m[35m (0.0ms)[0m rollback transaction
|
1896
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
1897
|
+
---------------------------------------------------------
|
1898
|
+
Code42ApiTest: test_time_as_json_returns_a_iso8601_string
|
1899
|
+
---------------------------------------------------------
|
1900
|
+
[1m[35m (0.0ms)[0m rollback transaction
|
1901
|
+
[1m[36m (0.1ms)[0m [1mbegin transaction[0m
|
1902
|
+
[1m[35m (0.1ms)[0m commit transaction
|
1903
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
1904
|
+
[1m[35m (0.0ms)[0m SAVEPOINT active_record_1
|
1905
|
+
[1m[36mSQL (0.0ms)[0m [1mINSERT INTO "authors" ("created_at", "first_name", "id", "last_name", "updated_at") VALUES (?, ?, ?, ?, ?)[0m [["created_at", "2014-01-01 06:00:00.000000"], ["first_name", "Stephen"], ["id", 3], ["last_name", "King"], ["updated_at", "2014-01-01 06:00:00.000000"]]
|
1906
|
+
[1m[35m (0.0ms)[0m RELEASE SAVEPOINT active_record_1
|
1907
|
+
Started PUT "/authors/3" for 127.0.0.1 at 2014-01-01 06:00:00 UTC
|
1908
|
+
Processing by AuthorsController#update as JSON
|
1909
|
+
Parameters: {"author"=>{"last_name"=>"Colbert"}, "id"=>"3"}
|
1910
|
+
[1m[36mAuthor Load (0.0ms)[0m [1mSELECT "authors".* FROM "authors" WHERE "authors"."id" = ? LIMIT 1[0m [["id", 3]]
|
1911
|
+
[1m[35m (0.0ms)[0m SAVEPOINT active_record_1
|
1912
|
+
[1m[36mSQL (0.0ms)[0m [1mUPDATE "authors" SET "last_name" = ? WHERE "authors"."id" = 3[0m [["last_name", "Colbert"]]
|
1913
|
+
[1m[35m (0.0ms)[0m RELEASE SAVEPOINT active_record_1
|
1914
|
+
Completed 200 OK in 0ms (Views: 0.0ms | ActiveRecord: 0.0ms)
|
1915
|
+
[1m[36m (0.5ms)[0m [1mrollback transaction[0m
|
1916
|
+
[1m[35m (0.1ms)[0m begin transaction
|
1917
|
+
[1m[36m (0.0ms)[0m [1mcommit transaction[0m
|
1918
|
+
[1m[35m (0.0ms)[0m begin transaction
|
1919
|
+
[1m[36m (0.0ms)[0m [1mSAVEPOINT active_record_1[0m
|
1920
|
+
[1m[35mSQL (0.0ms)[0m INSERT INTO "authors" ("created_at", "first_name", "id", "last_name", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-01-01 06:00:00.000000"], ["first_name", "Stephen"], ["id", 3], ["last_name", "King"], ["updated_at", "2014-01-01 06:00:00.000000"]]
|
1921
|
+
[1m[36m (0.0ms)[0m [1mRELEASE SAVEPOINT active_record_1[0m
|
1922
|
+
Started PUT "/authors/3" for 127.0.0.1 at 2014-01-01 06:00:00 UTC
|
1820
1923
|
Processing by AuthorsController#update as JSON
|
1821
1924
|
Parameters: {"author"=>{"last_name"=>nil}, "id"=>"3"}
|
1822
1925
|
[1m[35mAuthor Load (0.0ms)[0m SELECT "authors".* FROM "authors" WHERE "authors"."id" = ? LIMIT 1 [["id", 3]]
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: code42_api_rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nick Colgan
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-08-
|
11
|
+
date: 2014-08-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|