forked from samdods/dynamicCategoryProperties
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding some basic unit tests (currently 1 fails for issue samdods#3)
- Loading branch information
John McKerrell
committed
Sep 14, 2015
1 parent
2ea64a4
commit 657cedf
Showing
6 changed files
with
121 additions
and
26 deletions.
There are no files selected for viewing
This file contains 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
16 changes: 16 additions & 0 deletions
16
Example/DynamicCategoryPropertiesTests/BasicObject+Properties.h
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
// | ||
// BasicObject+Properties.h | ||
// DynamicCategoryProperties | ||
// | ||
// Created by John McKerrell on 14/09/2015. | ||
// Copyright © 2015 Sam Dods. All rights reserved. | ||
// | ||
|
||
#import "BasicObject.h" | ||
|
||
@interface BasicObject (Properties) | ||
|
||
@property (nonatomic, strong) NSNumber *propertyA; | ||
@property (nonatomic, strong) NSNumber *propertyB; | ||
|
||
@end |
23 changes: 23 additions & 0 deletions
23
Example/DynamicCategoryPropertiesTests/BasicObject+Properties.m
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
// | ||
// BasicObject+Properties.m | ||
// DynamicCategoryProperties | ||
// | ||
// Created by John McKerrell on 14/09/2015. | ||
// Copyright © 2015 Sam Dods. All rights reserved. | ||
// | ||
|
||
#import "BasicObject+Properties.h" | ||
|
||
#import "NSObject+DZLCategoryProperties.h" | ||
|
||
@implementation BasicObject (Properties) | ||
|
||
@dynamic propertyA; | ||
@dynamic propertyB; | ||
|
||
+ (void)load | ||
{ | ||
[self DZL_implementDynamicPropertyAccessors]; | ||
} | ||
|
||
@end |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
// | ||
// BasicObject.h | ||
// DynamicCategoryProperties | ||
// | ||
// Created by John McKerrell on 14/09/2015. | ||
// Copyright © 2015 Sam Dods. All rights reserved. | ||
// | ||
|
||
#import <Foundation/Foundation.h> | ||
|
||
@interface BasicObject : NSObject | ||
|
||
@end |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
// | ||
// BasicObject.m | ||
// DynamicCategoryProperties | ||
// | ||
// Created by John McKerrell on 14/09/2015. | ||
// Copyright © 2015 Sam Dods. All rights reserved. | ||
// | ||
|
||
#import "BasicObject.h" | ||
|
||
@implementation BasicObject | ||
|
||
@end |
This file contains 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