Skip to content

Commit

Permalink
Fix tests for Xcode 6.1
Browse files Browse the repository at this point in the history
  • Loading branch information
mxcl committed Nov 23, 2014
1 parent 1cc1606 commit 2b45ecd
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion tests
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,10 @@ int main() {
unlink("/tmp/YOLOtests");
@autoreleasepool {
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
XCTSelfTestMain();
#pragma clang diagnostic pop
}
}
Expand Down Expand Up @@ -595,7 +598,14 @@ int main() {
__EOBJC__

FRAMEWORKS = "/Applications/Xcode.app/Contents/Developer/Library/Frameworks"
FRAMEWORKS = begin
attempt1 = "/Applications/Xcode.app/Contents/Developer/Library/Frameworks"
if File.directory? "#{attempt1}/XCTest.framework"
attempt1
else
"/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks"
end
end

File.open('/tmp/YOLOtests.m', 'w') do |f|
f.puts("\n\n") # make line numbers line up
Expand Down

0 comments on commit 2b45ecd

Please sign in to comment.