GitHub PullRequestReviewCommentEvent at 2014-02-08 13:55:38
Repository: SMDataDiller
Actor: pirogoffSergey
Payload: {"comment":{"url":"https://api.github.com/repos/SMCorporation/SMDataDiller/pulls/comments/9563858","id":9563858,"diff_hunk":"@@ -17,18 +21,33 @@ @implementation SMDataDillerTests\n - (void)setUp\n {\n     [super setUp];\n-    // Put setup code here. This method is called before the invocation of each test method in the class.\n+    self.dataProvider = [[SMBaseDataProvider alloc] init];\n+    [self.dataProvider setItems:@[@\"Title1\", @\"TItle2\", @\"TItle3\", @\"TItle4\", @\"TItle5\"]];\n }\n \n - (void)tearDown\n {\n-    // Put teardown code here. This method is called after the invocation of each test method in the class.\n+    self.dataProvider = nil;\n     [super tearDown];\n }\n \n-- (void)testExample\n+- (void)testItemAtIndexPath\n {\n-    XCTFail(@\"No implementation for \\\"%s\\\"\", __PRETTY_FUNCTION__);\n+    NSString *item1 = [self.dataProvider itemAtIndexPath:[NSIndexPath indexPathForRow:2 inSection:0]];\n+    XCTAssertNotNil(item1, @\"item1 should not be nil\");\n+    \n+    NSString *item2 = [self.dataProvider itemAtIndexPath:[NSIndexPath indexPathForRow:1 inSection:1]];\n+    XCTAssertNil(item2, @\"item 2 should be nil\");\n+    \n+    NSIndexPath *inexOfItem2 = [self.dataProvider indexPathOfItem:item2];\n+    XCTAssertNil(inexOfItem2, @\"inexOfItem2 should be nil\");\n+    \n+    NSIndexPath *indexOfItem1 = [self.dataProvider indexPathOfItem:item1];\n+    XCTAssertNotNil(indexOfItem1, @\"indexOfItem1 should not be nil\");\n+    \n+    XCTAssertTrue([indexOfItem1 isEqual:[NSIndexPath indexPathForRow:2 inSection:0]], @\"indexOfItem1, row should equal 2, section 0\");","path":"SMDataDillerTests/SMDataDillerTests.m","position":46,"original_position":46,"commit_id":"5dce861fd908ca8e462cd49f82d6ffa6e4e207e9","original_commit_id":"5dce861fd908ca8e462cd49f82d6ffa6e4e207e9","user":{"login":"pirogoffSergey","id":1841884,"avatar_url":"https://gravatar.com/avatar/5c8180d1a67988a3128b580e3fa97328?d=https%3A%2F%2Fidenticons.github.com%2F2823f0c78ab78286d576113bae674cdf.png&r=x","gravatar_id":"5c8180d1a67988a3128b580e3fa97328","url":"https://api.github.com/users/pirogoffSergey","html_url":"https://github.com/pirogoffSergey","followers_url":"https://api.github.com/users/pirogoffSergey/followers","following_url":"https://api.github.com/users/pirogoffSergey/following{/other_user}","gists_url":"https://api.github.com/users/pirogoffSergey/gists{/gist_id}","starred_url":"https://api.github.com/users/pirogoffSergey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pirogoffSergey/subscriptions","organizations_url":"https://api.github.com/users/pirogoffSergey/orgs","repos_url":"https://api.github.com/users/pirogoffSergey/repos","events_url":"https://api.github.com/users/pirogoffSergey/events{/privacy}","received_events_url":"https://api.github.com/users/pirogoffSergey/received_events","type":"User","site_admin":false},"body":"А вообще, тесты это хорошо\r\n:+1: ","created_at":"2014-02-08T13:55:38Z","updated_at":"2014-02-08T13:55:38Z","html_url":"https://github.com/SMCorporation/SMDataDiller/pull/3#discussion_r9563858","pull_request_url":"https://api.github.com/repos/SMCorporation/SMDataDiller/pulls/3","_links":{"self":{"href":"https://api.github.com/repos/SMCorporation/SMDataDiller/pulls/comments/9563858"},"html":{"href":"https://github.com/SMCorporation/SMDataDiller/pull/3#discussion_r9563858"},"pull_request":{"href":"https://api.github.com/repos/SMCorporation/SMDataDiller/pulls/3"}}}}