Sha256: 2d6d2e55a5b9323e7d861af3b4b595a00a67c04aff76536013755b71364b522b

Contents?: true

Size: 816 Bytes

Versions: 49

Compression:

Stored size: 816 Bytes

Contents

require 'spec_helper'
require 'pact_broker/api/decorators/relationships_csv_decorator'

module PactBroker

  module Api

    module Decorators

      describe RelationshipsCsvDecorator do

        let(:pact) { TestDataBuilder.new.create_pact_with_hierarchy("My Consumer", "1.0", "My Provider").and_return(:pact) }
        let(:pacts) { [pact]}


        subject { RelationshipsCsvDecorator.new(pacts) }


        describe "#to_csv" do

          let(:line_1) { '1,My Consumer,1,3158419,0,1,2,0,0,0,0,0,0,0,0'}
          let(:line_2) { '2,My Provider,1,3158419,0,2,0,0,0,0,0,0,0,0,0' }
          let(:expected_text) { [line_1, line_2].join("\n") + "\n" }

          xit "returns the relationships as CSV" do
            expect(subject.to_csv).to eq expected_text
          end
        end

      end
    end
  end
end

Version data entries

49 entries across 49 versions & 1 rubygems

Version Path
pact_broker-2.23.0 spec/lib/pact_broker/api/decorators/relationships_csv_decorator_spec.rb
pact_broker-2.22.0 spec/lib/pact_broker/api/decorators/relationships_csv_decorator_spec.rb
pact_broker-2.21.0 spec/lib/pact_broker/api/decorators/relationships_csv_decorator_spec.rb
pact_broker-2.20.0 spec/lib/pact_broker/api/decorators/relationships_csv_decorator_spec.rb
pact_broker-2.19.2 spec/lib/pact_broker/api/decorators/relationships_csv_decorator_spec.rb
pact_broker-2.19.1 spec/lib/pact_broker/api/decorators/relationships_csv_decorator_spec.rb
pact_broker-2.19.0 spec/lib/pact_broker/api/decorators/relationships_csv_decorator_spec.rb
pact_broker-2.18.0 spec/lib/pact_broker/api/decorators/relationships_csv_decorator_spec.rb
pact_broker-2.17.1 spec/lib/pact_broker/api/decorators/relationships_csv_decorator_spec.rb
pact_broker-2.17.0 spec/lib/pact_broker/api/decorators/relationships_csv_decorator_spec.rb
pact_broker-2.16.1 spec/lib/pact_broker/api/decorators/relationships_csv_decorator_spec.rb
pact_broker-2.16.0 spec/lib/pact_broker/api/decorators/relationships_csv_decorator_spec.rb
pact_broker-2.15.0 spec/lib/pact_broker/api/decorators/relationships_csv_decorator_spec.rb
pact_broker-2.14.0 spec/lib/pact_broker/api/decorators/relationships_csv_decorator_spec.rb
pact_broker-2.13.1 spec/lib/pact_broker/api/decorators/relationships_csv_decorator_spec.rb
pact_broker-2.13.0 spec/lib/pact_broker/api/decorators/relationships_csv_decorator_spec.rb
pact_broker-2.12.0 spec/lib/pact_broker/api/decorators/relationships_csv_decorator_spec.rb
pact_broker-2.11.0 spec/lib/pact_broker/api/decorators/relationships_csv_decorator_spec.rb
pact_broker-2.10.0 spec/lib/pact_broker/api/decorators/relationships_csv_decorator_spec.rb
pact_broker-2.9.0 spec/lib/pact_broker/api/decorators/relationships_csv_decorator_spec.rb