Sha256: c3a26dce639241db53e32a2f8d669c2c0984eec02f873010cb638503393aba7c
Contents?: true
Size: 783 Bytes
Versions: 8
Compression:
Stored size: 783 Bytes
Contents
describe Spree::OptionValueSerializer do let(:option_value) { create :option_value } subject { ActiveModel::Serializer::Adapter::JsonApi.new(described_class.new option_value) } its(:to_json) do is_expected.to be_json_eql <<-JSON { "data" : { "attributes" : { "name" : "#{option_value.name}", "position" : #{option_value.position}, "presentation" : "#{option_value.presentation}" }, "relationships" : { "option_type" : { "data" : { "type" : "spree_option_types" } }, "variants" : { "data" : [] } }, "type" : "spree_option_values" } } JSON end end
Version data entries
8 entries across 8 versions & 3 rubygems