Sha256: 4cff0b347559207e019278c7d8cf3c7ed7aa3c70e6458f7ef040af499d145793

Contents?: true

Size: 519 Bytes

Versions: 1

Compression:

Stored size: 519 Bytes

Contents

require 'test_helper'

module Workarea
  class Forter::UpdateStatusTest < TestCase

    def test_decision_status_update
      decision = Workarea::Forter::Decision.create(id: '1234')

      details_hash = {
        orderId: 1234,
        eventTime: Time.new.to_i * 1000,
        updatedStatus: "CANCELED_BY_MERCHANT"
      }

      Workarea::Forter::UpdateStatus.new.perform(decision.id, details_hash)

      decision.reload

      assert_equal("CANCELED_BY_MERCHANT", decision.external_order_status)
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
workarea-forter-1.2.2 test/workers/forter/update_status_test.rb