Installing CocoaPods Fails

I’m trying to set up a build and run tests but I keep getting an error with Cocoapods. Attached a screenshot of the error.