spec/base_spec.rb in upholsterer-0.4.5 vs spec/base_spec.rb in upholsterer-0.5.0
- old
+ new
@@ -184,9 +184,17 @@
subject { ExposeAllPresenter.new(comment).to_json }
it { should eq '{}' }
end
+ describe 'serializable' do
+ describe 'with inheritance' do
+ subject { SerializablePresenter.new(double).to_json }
+
+ it { should eq '{"one":1,"two":2}'}
+ end
+ end
+
describe 'expose with block' do
let(:project) { double id: 1, description: 'description', type: 'type' }
subject { CollectPresenter.new(entity) }
context 'Test presenter' do