forked from mykeepass/KeePassLib
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDataSourceTests.m
45 lines (37 loc) · 949 Bytes
/
DataSourceTests.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
//
// DataSourceTests.m
// KeePass2
//
// Created by Qiang Yu on 2/3/10.
// Copyright 2010 __MyCompanyName__. All rights reserved.
//
#import "DataSourceTests.h"
#import "WrapperNSData.h"
#import "GZipInputData.h"
@implementation DataSourceTests
-(void) testWrappedNSData{
/*
WrapperNSData * data = [[WrapperNSData alloc] initWithContentsOfMappedFile:@"DataSourceTests.m"];
uint8_t buffer[64];
uint32_t read;
do{
read = [data readBytes:buffer length:64];
NSLog(@"# of bytes read: %d", read);
}while(read);
*/
}
- (void) testGUnzip{
/*
uint32_t total = 0;
WrapperNSData * data = [[WrapperNSData alloc] initWithContentsOfMappedFile:@"/Volumes/Users/qiang/Desktop/test.gz"];
GZipInputData * gzip = [[GZipInputData alloc] initWithDataSource:data];
uint8_t buffer[1024];
uint32_t read;
do{
read = [gzip readBytes:buffer length:1024];
total += read;
}while(read);
NSLog(@"==># of bytes read: %d", total);
*/
}
@end