-
Notifications
You must be signed in to change notification settings - Fork 644
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added detect cross references task to the project.
- Loading branch information
Showing
7 changed files
with
107 additions
and
0 deletions.
There are no files selected for viewing
39 changes: 39 additions & 0 deletions
39
AppledocTests/Processing/DetectCrossReferencesTaskTests.mm
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,39 @@ | ||
// | ||
// DetectCrossReferencesTaskTests.m | ||
// appledoc | ||
// | ||
// Created by Tomaz Kragelj on 24/11/12. | ||
// Copyright (c) 2012 Tomaz Kragelj. All rights reserved. | ||
// | ||
|
||
#import "Store.h" | ||
#import "DetectCrossReferencesTask.h" | ||
#import "TestCaseBase.hh" | ||
|
||
static void runWithTask(void(^handler)(DetectCrossReferencesTask *task, id comment)) { | ||
DetectCrossReferencesTask *task = [[DetectCrossReferencesTask alloc] init]; | ||
CommentInfo *comment = [[CommentInfo alloc] init]; | ||
handler(task, comment); | ||
[task release]; | ||
} | ||
|
||
static void setupComment(id comment, NSString *first ...) { | ||
va_list args; | ||
va_start(args, first); | ||
NSMutableArray *sections = [@[] mutableCopy]; | ||
for (NSString *arg=first; arg!=nil; arg=va_arg(args, NSString *)) { | ||
[sections addObject:arg]; | ||
} | ||
va_end(args); | ||
|
||
if ([comment isKindOfClass:[CommentInfo class]]) | ||
[comment setSourceSections:sections]; | ||
else | ||
[given([comment sourceSections]) willReturn:sections]; | ||
} | ||
|
||
#pragma mark - | ||
|
||
TEST_BEGIN(DetectCrossReferencesTaskTests) | ||
|
||
TEST_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
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
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 @@ | ||
// | ||
// DetectCrossReferencesTask.h | ||
// appledoc | ||
// | ||
// Created by Tomaz Kragelj on 24.11.12. | ||
// Copyright (c) 2012 Tomaz Kragelj. All rights reserved. | ||
// | ||
|
||
#import "ProcessorTask.h" | ||
|
||
@interface DetectCrossReferencesTask : ProcessorTask | ||
|
||
@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,21 @@ | ||
// | ||
// DetectCrossReferencesTask.m | ||
// appledoc | ||
// | ||
// Created by Tomaz Kragelj on 24.11.12. | ||
// Copyright (c) 2012 Tomaz Kragelj. All rights reserved. | ||
// | ||
|
||
#import "Objects.h" | ||
#import "Store.h" | ||
#import "DetectCrossReferencesTask.h" | ||
|
||
@implementation DetectCrossReferencesTask | ||
|
||
#pragma mark - Processing | ||
|
||
- (NSInteger)processComment:(CommentInfo *)comment { | ||
return GBResultOk; | ||
} | ||
|
||
@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
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