LoginSignup
0
0

More than 5 years have passed since last update.

XCTestからKinesis#putRecordsを実行するとNSInternalInconsistencyExceptionが発生

Posted at

概要

XCTestからAWSKinesis#putRecordsを実行するとNSInternalInconsistencyExceptionが発生する。XCTest以外からは正常に実行される。

例外内容:

failed: caught "NSInternalInconsistencyException", "Invalid parameter not satisfying: [modelClass isSubclassOfClass:AWSMTLModel.class]"

環境

  • Xcode7
  • Cocoapods 0.38.2
  • Objective-c

原因

AWSCore内にインストールされているMantleが重複インストールされるとこのエラーが発生する(らしい)。

対策

Test用のターゲットにexclusiveオプションを設定して重複インストールされれないようにする。

platform :ios, '8.0'

pod 'AWSiOSSDKv2/Kinesis'

target :ExampleTest, exclusive: true do
    pod 'OCMock'
end

参考

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0