Commit Graph

848 Commits

Author SHA1 Message Date
Theodore Konukhov
26c0847563 - If a controller is in a namespace, serializer will be looked up in this namespace first.
- Serializers for associations will be looked up in a parent serializer's namespace first too.
- "Prefix" option for different versions of associations serializers. Example: has_many :users, as: :short -> ShortUserSerializer

TODO: tests, config option for enabling namespace lookup
2014-08-24 15:57:24 +02:00
Radan Skoric
ddfd8d2c11 embed_in_root works even if serializer is invoked through another serializers' association which itself does not have embed_in_root set 2014-08-23 18:21:24 +02:00
Steve Klabnik
2fec5111ef Bump version to 0.9.0 2014-08-22 16:17:46 -04:00
Steve Klabnik
55831dd2b0 update README 2014-08-22 16:17:46 -04:00
Steve Klabnik
ae7959b76e Merge pull request #512 from TimPetricola/fix-options-access
Custom options are accessible in serializer
2014-08-22 16:15:41 -04:00
Steve Klabnik
74625f778b Merge pull request #594 from bolshakov/feature/custom_array_serializer
Support custom array serializer
2014-08-22 15:28:26 -04:00
Steve Klabnik
e9378cc9ab Merge pull request #595 from bolshakov/feature/array_serializer_options
Array serializer pass except and only options to item serializers
2014-08-22 15:26:17 -04:00
Steve Klabnik
92f1db0137 Merge pull request #596 from bolshakov/feature/instumentation
Test::Unit assert_serializer implemented
2014-08-22 15:25:52 -04:00
Steve Klabnik
3c124e8ce5 Clarify README wrt POROs
Closes #556.
2014-08-22 14:52:39 -04:00
Steve Klabnik
5cb0875286 Merge pull request #598 from joshk/patch-1
Use the new Docker queue
2014-08-21 23:59:11 -04:00
Josh Kalderimis
035f261180 Use the new Docker queue
starts in seconds

faster better stronger
2014-08-22 01:18:36 +02:00
Tema Bolshakov
699b378984 remove nested case 2014-08-20 12:35:23 +04:00
Tema Bolshakov
c5d9d97f26 Assert with serializer class 2014-08-20 12:34:34 +04:00
Tema Bolshakov
865ab64025 rename spec file 2014-08-20 11:33:39 +04:00
Tema Bolshakov and Dmitry Myaskovskiy
aa66592a80 Update docs 2014-08-18 18:24:07 +04:00
Arthur Nogueira Neves
9fb343b5fb Merge pull request #591 from donbobka/feature/fix_format_keys_for_array_wo_root
Feature/fix format keys for array wo root
2014-08-18 10:21:37 -04:00
Tema Bolshakov and Dmitry Myaskovskiy
eaedcefa4e Test::Unit assert_serializer implemented
So you can assert specific serializer to be used.
2014-08-18 18:04:51 +04:00
Tema Bolshakov
e3ab34dd74 Array serializer pass except and only options to item serializers 2014-08-18 14:21:08 +04:00
Tema Bolshakov
6869cc9c3b No need to instantiate serializer 2014-08-18 12:47:22 +04:00
Tema Bolshakov
c389ae2207 Support customer array serializer 2014-08-18 12:37:01 +04:00
Steve Klabnik
be6ff586a2 Merge pull request #593 from byroot/fix-tests-broken-by-592
Manually include AC::Serialization module in test suite
2014-08-17 20:35:34 -04:00
Jean Boussier
6f8343d06e Manually include AC::Serialization module in test suite 2014-08-16 20:39:38 -04:00
Vladimir Lyzo
adcea6aaf0 Fix failing test: option format_key with root option 2014-08-15 16:21:40 +04:00
Vladimir Lyzo
c4e6cd48b6 Add failing test: serialize array with format_keys w/o root 2014-08-15 14:45:51 +04:00
Steve Klabnik
82e40b8a3c Merge pull request #592 from byroot/disable-ac-extension
Allow users to opt-out from the ActionController extensions
2014-08-14 17:04:11 -04:00
Jean Boussier
0d31e72d22 Allow users to opt-out from the ActionController extensions 2014-08-14 10:28:36 -04:00
Steve Klabnik
7e7d8a721c Merge pull request #461 from fivetanley/embed-in-root-key
Add embed_namespace and embed_in_root_key options
2014-08-13 13:28:28 -04:00
Stanley Stuart
e650863c6d fix tests from rebasing master for embed_namespace 2014-08-13 11:38:01 -05:00
Steve Klabnik
b9d216debd Merge pull request #570 from letuboy/patch-1
fix uninitialized instance variable warning
2014-08-02 17:17:38 -04:00
Paul Henry
76263865a7 fix uninitialized instance variable warning
Ruby warns that `@only` and `@except` are not initialized because if they are not passed in, they are never assigned.

Remove circular require in array_serializer
2014-08-02 14:05:37 -07:00
Tim Petricola
14b1df5c36 Custom options are accessible in serializer (via :context) 2014-07-28 13:10:02 -04:00
Steve Klabnik
045ba2a48c Merge pull request #534 from kylefritz/master
Support lowerCamel key format
2014-07-28 12:43:36 -04:00
Steve Klabnik
723049e28f Merge pull request #493 from shakirshakiel/master
fixing sideloading of nested associations
2014-07-28 12:34:17 -04:00
Steve Klabnik
e185becd5d allow failure on rails master 2014-07-04 22:49:36 -04:00
Steve Klabnik
e316532eef Fix up .travis.yml 2014-07-04 22:15:06 -04:00
Steve Klabnik
55fc6536fe Remove Coveralls
Coveralls is fine, but it's interfering with Travis somehow.
2014-07-04 22:11:49 -04:00
Steve Klabnik
0c2691a46d Merge pull request #518 from ebouchut/patch-2
Fix a typo.
2014-07-04 18:30:57 -07:00
Steve Klabnik
eb06f0315f Merge pull request #517 from ebouchut/patch-1
Fix a typo.
2014-07-04 18:30:53 -07:00
Kyle Fritz
76c8de7b9f root key format 2014-04-14 13:45:12 -04:00
Kyle Fritz
00c54baae3 Support lowerCamel key format 2014-03-30 12:31:21 -04:00
Wojtek Mach
2e31a14125 Add :only/:except options 2014-03-12 16:55:08 -03:00
Arthur Nogueira Neves
3201c63162 Merge pull request #524 from depy/master
Adds an example for using ArraySerializer under Render independently.
2014-03-11 08:41:13 -04:00
Arthur Nogueira Neves
289dfac743 Merge pull request #528 from arthurnn/travis_one_file
Few Travis configs
2014-03-10 20:17:38 -04:00
Arthur Neves
c8d0a5408b
Use minitest 4.7.x on rails 3.2 2014-03-10 20:00:49 -04:00
Ken Ip
8ca4d4fcd6 HasOne nil object should return [] under embedded key.
Ensure that @wrap_in_array is always respected when set to true even
when associated object is nil.
2014-03-10 16:42:04 -03:00
Arthur Neves
a19e95c83c
test on rails 4.1 2014-03-10 15:30:06 -04:00
Arthur Neves
9f7f267c8f Test against ruby 2.1.1 2014-03-10 15:28:46 -04:00
Arthur Neves
1e952ea702 Use new ENV on travis 2014-03-10 15:28:29 -04:00
Arthur Neves
488f257821
Use RAILS_VERSION on Gemfile 2014-03-10 15:27:37 -04:00
Arthur Neves
b6520315d8
only require coverage_setup on CI 2014-03-10 15:23:09 -04:00