Sha256: ef2b8dd130386d6b62c511ad2b2fb6a80b933f7cc16a5847836f9dc349303977
Contents?: true
Size: 554 Bytes
Versions: 34
Compression:
Stored size: 554 Bytes
Contents
require "spec_helper" describe Intercom::UserResource do describe "requires_params" do it "raises if they are missing" do params = {"a" => 1, "b" => 2} Intercom::UserResource.requires_parameters(params, %W(a b)) expected_message = "Missing required parameters (c)." proc { Intercom::UserResource.requires_parameters(params, %W(a b c)) }.must_raise ArgumentError, expected_message capture_exception { Intercom::UserResource.requires_parameters(params, %W(a b c)) }.message.must_equal expected_message end end end
Version data entries
34 entries across 34 versions & 1 rubygems