Sha256: 3386b1c372a3d805d7834aee508b73180db0de291487e730dbeb91a0b9072ace

Contents?: true

Size: 1.02 KB

Versions: 2

Compression:

Stored size: 1.02 KB

Contents

require "spec_helper"

describe IOSConfigProfile::SecurityPayload do
  let(:security_payload_attributes) do
    {
      "Password" => "password",
      "PayloadUUID" => "00000000-0000-0000-0000-000000000000",
      "PayloadCertificateFileName" => "identity.p12",

      "PayloadType" => "com.apple.security.pkcs12",
      "PayloadVersion" => 1,
      "PayloadIdentifier" => "#{IOSConfigProfile.root_domain}ipcu.profile.credential",
      "PayloadDisplayName" => "Security",
      "PayloadDescription" => "Provides device authentication (certificate or identity).",
      "PayloadOrganization" => IOSConfigProfile.organization,
    }
  end

  before do
    allow_any_instance_of(IOSConfigProfile::SecurityPayload).to receive_messages random_uuid: "00000000-0000-0000-0000-000000000000"
  end

  subject { IOSConfigProfile::SecurityPayload.new("identity", "password") }

  it { is_expected.to include security_payload_attributes }
  it "contains valid PayloadContent" do
    expect(subject["PayloadContent"].read).to eq("identity")
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
ios_config_profile-1.4.1 spec/device/security_payload_spec.rb
ios_config_profile-1.4.0 spec/device/security_payload_spec.rb