Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Remove leftover release / autorelease calls from tests

  • Loading branch information...
commit feac68f5e3c4aa1df629c4194cb511b7b5065640 1 parent cb624fb
@stig authored
Showing with 2 additions and 15 deletions.
  1. +0 −5 Tests/JsonTestCase.m
  2. +1 −5 Tests/ProxyTest.m
  3. +1 −5 Tests/WriterTest.m
View
5 Tests/JsonTestCase.m
@@ -41,11 +41,6 @@ - (void)setUp {
writer = [[SBJsonWriter alloc] init];
}
-- (void)tearDown {
- [parser release];
- [writer release];
-}
-
- (NSString*)otherFileName {
return @"output";
}
View
6 Tests/ProxyTest.m
@@ -55,7 +55,7 @@ @interface Bool : NSObject
@implementation Bool
- (id)proxyForJson {
- return [NSArray arrayWithObjects:[[True new] autorelease], [[False new] autorelease], nil];
+ return [NSArray arrayWithObjects:[True new], [False new], nil];
}
@end
@@ -79,10 +79,6 @@ - (void)setUp {
writer = [SBJsonWriter new];
}
-- (void)tearDown {
- [writer release];
-}
-
- (void)testUnsupportedWithoutProxy {
STAssertNil([writer stringWithObject:[NSArray arrayWithObject:[NSObject new]]], nil);
STAssertEqualObjects(writer.error, @"JSON serialisation not supported for NSObject", nil);
View
6 Tests/WriterTest.m
@@ -42,10 +42,6 @@ - (void)setUp {
writer = [SBJsonWriter new];
}
-- (void)tearDown {
- [writer release];
-}
-
- (void)testInfinity {
STAssertEqualObjects(@"[0]", [writer stringWithObject:[NSArray arrayWithObject:[NSNumber numberWithDouble:0.0]]], nil);
STAssertEqualObjects(@"[-0]", [writer stringWithObject:[NSArray arrayWithObject:[NSNumber numberWithDouble:-0.0]]], nil);
@@ -73,7 +69,7 @@ - (void)testTimeInterval {
- (void)testWriteToStream {
- SBJsonStreamWriter *streamWriter = [[[SBJsonStreamWriter alloc] init] autorelease];
+ SBJsonStreamWriter *streamWriter = [[SBJsonStreamWriter alloc] init];
STAssertTrue([streamWriter writeArray:[NSArray array]], nil);
Please sign in to comment.
Something went wrong with that request. Please try again.