Sha256: 79ab8ee5491d349e02471f3eb458423a1a242dd9d894413bc864811b56a77e22

Contents?: true

Size: 1.04 KB

Versions: 6

Compression:

Stored size: 1.04 KB

Contents

require "embulk/input/marketo_api/soap/base"
require "lead_fixtures"

module Embulk
  module Input
    module MarketoApi
      module Soap
        class BaseTest < Test::Unit::TestCase
          include LeadFixtures

          class TestSignature < self
            def setup
              @signature = soap.__send__(:signature)
            end

            def test_sigature_keys
              assert_equal(%w(requestTimestamp requestSignature).sort, @signature.keys.sort)
            end

            def test_is_hash
              assert_equal(Hash, @signature.class)
            end
          end

          private

          def soap
            @soap ||= Base.new(settings[:endpoint], settings[:wsdl], settings[:user_id], settings[:encryption_key])
          end

          def settings
            {
              endpoint: "https://marketo.example.com",
              wsdl: "https://marketo.example.com/?wsdl",
              user_id: "user_id",
              encryption_key: "TOPSECRET",
            }
          end
        end
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
embulk-input-marketo-0.2.3 test/embulk/input/marketo_api/soap/test_base.rb
embulk-input-marketo-0.2.2 test/embulk/input/marketo_api/soap/test_base.rb
embulk-input-marketo-0.2.1 test/embulk/input/marketo_api/soap/test_base.rb
embulk-input-marketo-0.2.0 test/embulk/input/marketo_api/soap/test_base.rb
embulk-input-marketo-0.1.1 test/embulk/input/marketo_api/soap/test_base.rb
embulk-input-marketo-0.1.0 test/embulk/input/marketo_api/soap/test_base.rb