Created
October 3, 2012 19:12
-
-
Save ErikEvenson/3829115 to your computer and use it in GitHub Desktop.
RKPathMatcher Test
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
- (void)testAddedTest | |
{ | |
NSDictionary *arguments = nil; | |
RKPathMatcher *pathMatcher = [RKPathMatcher pathMatcherWithPattern:@"/api/v1/organizations"]; | |
BOOL isMatchingPattern = [pathMatcher matchesPath:@"/api/v1/organizations?name__icontains=t" tokenizeQueryStrings:YES parsedArguments:&arguments]; | |
assertThatBool(isMatchingPattern, is(equalToBool(YES))); | |
assertThat(arguments, isNot(empty())); | |
assertThat(arguments, hasEntries(@"name__icontains", @"t",nil)); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment