This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #ifdef __OBJC__ | |
| ... | |
| #import <CoreData/CoreData.h> | |
| #endif |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @property (nonatomic, retain, readonly) NSManagedObjectContext *managedObjectContext; | |
| @property (nonatomic, retain, readonly) NSManagedObjectModel *managedObjectModel; | |
| @property (nonatomic, retain, readonly) NSPersistentStoreCoordinator *persistentStoreCoordinator; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| - (void) testCellSecondaryTextLabelIsOfExpectedType | |
| { | |
| MyTableViewCell *cell = [[MyTableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:@"cell"]; | |
| GHAssertTrue([cell.textLabel2 isMemberOfClass:[MyUILabel class]], | |
| @"Class is: %@", NSStringFromClass ([cell class])); | |
| } | |
| - (void) testCellSecondaryTextLabelInheritsFromUILabel | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| - (void) testCellSecondaryTextLabelIsOfExpectedType | |
| { | |
| MyTableViewCell *cell = [[MyTableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:@"cell"]; | |
| GHAssertTrue([cell.textLabel2 isMemberOfClass:[UILabel class]], | |
| @"Class is: %@", NSStringFromClass ([cell.textLabel2 class])); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * | |
| * Test: Black box | |
| */ | |
| public function testUploadedFilePersistsInFileSystem() | |
| { | |
| // Vars | |
| $id = 1; | |
| $allowedOwners = array('nobody', 'www-data'); | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public function setUp() | |
| { | |
| exec( | |
| "curl --silent " | |
| . "-F upload=@'/path/to/file/testFile.txt' " | |
| . "-F name=phpunitFileUpload " | |
| . 'http://application.com/files/upload'); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * Test class | |
| */ | |
| class FilesControllerTest extends Zend_Test_PHPUnit_ControllerTestCase | |
| { | |
| public function testAddingFileNowExistsInFolder() | |
| { | |
| $this->assertTrue(file_exists('/upload/path/testFile.txt')); | |
| } | |
| } |
NewerOlder