Sha256: c1adc1f8a908b9c8567b731abb38fca08eb4f3150fd3c8c1fb60217ad18d1932

Contents?: true

Size: 513 Bytes

Versions: 1

Compression:

Stored size: 513 Bytes

Contents

# frozen_string_literal: true

RSpec.describe BingAdsRubySdk::Postprocessors::CastLongArrays do
  def action(params)
    described_class.new(params).call
  end

  it "casts and simplifies long arrays" do
    expect(action({
      long: "foo",
      bar_bar: {
        long: ["1", "2"]
      },
      foos: [
        {
          bar: {
            long: ["3", "4"]
          }
        }
      ]
    })).to eq({
      long: "foo",
      bar_bar: [1, 2],
      foos: [
        {bar: [3, 4]}
      ]
    })
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
bing_ads_ruby_sdk-1.5.0 spec/bing_ads_ruby_sdk/postprocessors/cast_long_arrays_spec.rb