I am trying to get started with tdd within Xcode, and followed a very nice tutorial.
Everything went well. However, when I want to make a command line application (in c) project in Xcode a separate test-folder was not created.
I want to build a random graph implementation, and my project graph consists of main.c, graph.h and graph.c. I decided to add a test-file (objective C test file case).
Here, I have the import XCTest/XCTest.h but when running (Product->run) I get the error that XCTest/XCTest.h is not found. I also do not get to run test mode (Product-test).
why is that header-file not found? and how do I fix it?
XCTest/XCTest.h will work for testTarget only not for other targets try to remove targets for your xxxtest.m file. you can do that by removeing it form compileSources of that target
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With