Sha256: 0320796c1882dd5f6b9cf5f9d8ef639d4e3210921d39dffb06742c5382f619bd
Contents?: true
Size: 655 Bytes
Versions: 8
Compression:
Stored size: 655 Bytes
Contents
describe Spree::TaxonomySerializer do let(:taxonomy) { create :taxonomy } subject { ActiveModel::Serializer::Adapter::JsonApi.new(described_class.new taxonomy) } its(:to_json) do is_expected.to be_json_eql <<-JSON { "data" : { "attributes" : { "name" : "#{taxonomy.name}", "position" : #{taxonomy.position} }, "relationships" : { "taxons" : { "data" : [ { "type" : "spree_taxons" } ] } }, "type" : "spree_taxonomies" } } JSON end end
Version data entries
8 entries across 8 versions & 3 rubygems