Skip to content
Permalink
Browse files

Configure SPMySQL project to actually be able to run Unit Tests

* Add a new configuration "Unit Tests"
* Add a new Target for the Unit Test code
* Assign Unit Test Target to the Test step of SPMySQL scheme

* Also remove a compiler setting for PowerMac G5
  • Loading branch information...
dmoagx committed Oct 4, 2015
1 parent 0263046 commit 05f9533860eb53e5fd0028cda74f9b6d7b26454d
@@ -28,6 +28,12 @@
//
// More info at <https://github.com/sequelpro/sequelpro>

#import <Cocoa/Cocoa.h>
#import <XCTest/XCTest.h>

// this function is inaccessible outside of unit tests
extern NSString * _bitStringWithBytes(const char *bytes, NSUInteger length, NSUInteger padLength);

@interface DataConversion_Tests : XCTestCase

- (void)test_bitStringWithBytes;
@@ -40,10 +46,10 @@ - (void)test_bitStringWithBytes
{
// BIT(1)
{
unsigned char y = 1;
unsigned char n = 0;
const char y = '\1';
const char n = '\0';
XCTAssertEqualObjects(_bitStringWithBytes(&y,sizeof(y),1), @"1");
XCTAssertEqualObjects(_bitStringWithBytes(&n,sizeof(n),0), @"0");
XCTAssertEqualObjects(_bitStringWithBytes(&n,sizeof(n),1), @"0");
}
// BIT(3)
{
@@ -0,0 +1,24 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key>
<string>com.sequelpro.spmysql-unittests</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string>
<key>CFBundlePackageType</key>
<string>BNDL</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>1</string>
</dict>
</plist>
Oops, something went wrong.

0 comments on commit 05f9533

Please sign in to comment.
You can’t perform that action at this time.