1

I'm attempting to use the Quick/Nimble testing framework in the iOS application at work. When I build my xcworkspace project I get all the errors in the image below. All these errors are within the Pods.xcodeproj in Pods/Nimble folder.

I'm using Swift 3, Xcode 8.0, Cocoapods 1.1.1, fastlane 1.10.5, Nimble 5.1.1, Quick 0.10.0, and Swiftlint. Are these errors caused by Swiftlint, Swift 3, or something else?

enter image description here

ltrainpr
  • 3,115
  • 3
  • 29
  • 40
  • 1
    There are no errors. Those are simple messages from lint telling you that those specific Swift files use bad naming conventions. Though the "force try violation" messages shouldn't be ignored. – rmaddy Nov 16 '16 at 22:41
  • @rmaddy How do I get my project to build if these are not errors? – ltrainpr Nov 16 '16 at 22:50
  • Lint must be setup to force the build to fail. If you weren't using lint the build would be fine. Naming convention issues have no impact on whether an app works correctly or not. Some of the lint message you see are probably more important and fixing those issues could help avoid some bugs. – rmaddy Nov 16 '16 at 22:53
  • Ok, so I need to figure out how to disable the lint for the Quick-Nimble testing framework or perhaps all 3rd party libraries. – ltrainpr Nov 16 '16 at 22:55
  • 1
    That's probably best since you have no control over the code of such libraries. Use lint to clean up your own code. Though it might be helpful to let the library developer know that their code has a lot of issues. – rmaddy Nov 16 '16 at 22:56

1 Answers1

1

In order to disable Swiftlint from checking the Pods folder I added this code to .swiftlint.yml file:

excluded: # paths to ignore during linting. Takes precedence over `included`.
  - Pods

This solved my problem as the errors were stopping me from building the project. The .swiftlint.yml file goes at the same level as your Xcode project folder.

I'm presuming that you added Quick and Nimble using Cocoapods. If not you may have to add a different folder/project to exclude.

ltrainpr
  • 3,115
  • 3
  • 29
  • 40