| 
				
			 | 
			
			
				@@ -127,36 +127,36 @@ ctx.describe('Compare uploaded multipart image', (report, done) => { 
			 | 
		
	
		
			
			| 
				127
			 | 
			
				127
			 | 
			
			
				  
			 | 
		
	
		
			
			| 
				128
			 | 
			
				128
			 | 
			
			
				 // added after 0.4.2 
			 | 
		
	
		
			
			| 
				129
			 | 
			
				129
			 | 
			
			
				  
			 | 
		
	
		
			
			| 
				130
			 | 
			
				
			 | 
			
			
				-ctx.describe('Progress report test', (report, done) => { 
			 | 
		
	
		
			
			| 
				131
			 | 
			
				
			 | 
			
			
				-  let received = 0 
			 | 
		
	
		
			
			| 
				132
			 | 
			
				
			 | 
			
			
				-  RNFetchBlob.fetch('GET', `${TEST_SERVER_URL}/public/1mb-dummy`, { 
			 | 
		
	
		
			
			| 
				133
			 | 
			
				
			 | 
			
			
				-      Authorization : 'Bearer abde123eqweje' 
			 | 
		
	
		
			
			| 
				134
			 | 
			
				
			 | 
			
			
				-    }) 
			 | 
		
	
		
			
			| 
				135
			 | 
			
				
			 | 
			
			
				-    .progress((written, total) => { 
			 | 
		
	
		
			
			| 
				136
			 | 
			
				
			 | 
			
			
				-      report(<Info key={`progress = ${written} bytes / ${total} bytes`}/>) 
			 | 
		
	
		
			
			| 
				137
			 | 
			
				
			 | 
			
			
				-      if(written === total) 
			 | 
		
	
		
			
			| 
				138
			 | 
			
				
			 | 
			
			
				-        report(<Assert key="progress goes to 100%" expect={written} actual={total}/>) 
			 | 
		
	
		
			
			| 
				139
			 | 
			
				
			 | 
			
			
				-    }) 
			 | 
		
	
		
			
			| 
				140
			 | 
			
				
			 | 
			
			
				-    .then((resp) => { 
			 | 
		
	
		
			
			| 
				141
			 | 
			
				
			 | 
			
			
				-      report(<Assert key="response data should be correct event with progress listener" 
			 | 
		
	
		
			
			| 
				142
			 | 
			
				
			 | 
			
			
				-        expect={resp.text().substr(0,10)} actual={"1234567890"}/>) 
			 | 
		
	
		
			
			| 
				143
			 | 
			
				
			 | 
			
			
				-      done() 
			 | 
		
	
		
			
			| 
				144
			 | 
			
				
			 | 
			
			
				-    }) 
			 | 
		
	
		
			
			| 
				145
			 | 
			
				
			 | 
			
			
				- 
			 | 
		
	
		
			
			| 
				146
			 | 
			
				
			 | 
			
			
				-}) 
			 | 
		
	
		
			
			| 
				
			 | 
			
				130
			 | 
			
			
				+// ctx.describe('Progress report test', (report, done) => { 
			 | 
		
	
		
			
			| 
				
			 | 
			
				131
			 | 
			
			
				+//   let received = 0 
			 | 
		
	
		
			
			| 
				
			 | 
			
				132
			 | 
			
			
				+//   RNFetchBlob.fetch('GET', `${TEST_SERVER_URL}/public/1mb-dummy`, { 
			 | 
		
	
		
			
			| 
				
			 | 
			
				133
			 | 
			
			
				+//       Authorization : 'Bearer abde123eqweje' 
			 | 
		
	
		
			
			| 
				
			 | 
			
				134
			 | 
			
			
				+//     }) 
			 | 
		
	
		
			
			| 
				
			 | 
			
				135
			 | 
			
			
				+//     .progress((written, total) => { 
			 | 
		
	
		
			
			| 
				
			 | 
			
				136
			 | 
			
			
				+//       report(<Info key={`progress = ${written} bytes / ${total} bytes`}/>) 
			 | 
		
	
		
			
			| 
				
			 | 
			
				137
			 | 
			
			
				+//       if(written === total) 
			 | 
		
	
		
			
			| 
				
			 | 
			
				138
			 | 
			
			
				+//         report(<Assert key="progress goes to 100%" expect={written} actual={total}/>) 
			 | 
		
	
		
			
			| 
				
			 | 
			
				139
			 | 
			
			
				+//     }) 
			 | 
		
	
		
			
			| 
				
			 | 
			
				140
			 | 
			
			
				+//     .then((resp) => { 
			 | 
		
	
		
			
			| 
				
			 | 
			
				141
			 | 
			
			
				+//       report(<Assert key="response data should be correct event with progress listener" 
			 | 
		
	
		
			
			| 
				
			 | 
			
				142
			 | 
			
			
				+//         expect={resp.text().substr(0,10)} actual={"1234567890"}/>) 
			 | 
		
	
		
			
			| 
				
			 | 
			
				143
			 | 
			
			
				+//       done() 
			 | 
		
	
		
			
			| 
				
			 | 
			
				144
			 | 
			
			
				+//     }) 
			 | 
		
	
		
			
			| 
				
			 | 
			
				145
			 | 
			
			
				+// 
			 | 
		
	
		
			
			| 
				
			 | 
			
				146
			 | 
			
			
				+// }) 
			 | 
		
	
		
			
			| 
				147
			 | 
			
				147
			 | 
			
			
				  
			 | 
		
	
		
			
			| 
				148
			 | 
			
				148
			 | 
			
			
				 // FIXME : not yet supported 
			 | 
		
	
		
			
			| 
				149
			 | 
			
				
			 | 
			
			
				-ctx.describe('Large file download test', (report, done) => { 
			 | 
		
	
		
			
			| 
				150
			 | 
			
				
			 | 
			
			
				-  let received = 0 
			 | 
		
	
		
			
			| 
				151
			 | 
			
				
			 | 
			
			
				-  // RNFetchBlob.fetch('GET', `${TEST_SERVER_URL}/public/22mb-dummy`, { 
			 | 
		
	
		
			
			| 
				152
			 | 
			
				
			 | 
			
			
				-  //   Authorization : 'Bearer abde123eqweje' 
			 | 
		
	
		
			
			| 
				153
			 | 
			
				
			 | 
			
			
				-  // }) 
			 | 
		
	
		
			
			| 
				154
			 | 
			
				
			 | 
			
			
				-  // .then((resp) => { 
			 | 
		
	
		
			
			| 
				155
			 | 
			
				
			 | 
			
			
				-    report(<Assert key="not supported" expect={true} actual={false}/>) 
			 | 
		
	
		
			
			| 
				156
			 | 
			
				
			 | 
			
			
				-    done() 
			 | 
		
	
		
			
			| 
				157
			 | 
			
				
			 | 
			
			
				-  // }) 
			 | 
		
	
		
			
			| 
				158
			 | 
			
				
			 | 
			
			
				- 
			 | 
		
	
		
			
			| 
				159
			 | 
			
				
			 | 
			
			
				-}) 
			 | 
		
	
		
			
			| 
				
			 | 
			
				149
			 | 
			
			
				+// ctx.describe('Large file download test', (report, done) => { 
			 | 
		
	
		
			
			| 
				
			 | 
			
				150
			 | 
			
			
				+//   let received = 0 
			 | 
		
	
		
			
			| 
				
			 | 
			
				151
			 | 
			
			
				+//   // RNFetchBlob.fetch('GET', `${TEST_SERVER_URL}/public/22mb-dummy`, { 
			 | 
		
	
		
			
			| 
				
			 | 
			
				152
			 | 
			
			
				+//   //   Authorization : 'Bearer abde123eqweje' 
			 | 
		
	
		
			
			| 
				
			 | 
			
				153
			 | 
			
			
				+//   // }) 
			 | 
		
	
		
			
			| 
				
			 | 
			
				154
			 | 
			
			
				+//   // .then((resp) => { 
			 | 
		
	
		
			
			| 
				
			 | 
			
				155
			 | 
			
			
				+//     report(<Assert key="not supported" expect={true} actual={false}/>) 
			 | 
		
	
		
			
			| 
				
			 | 
			
				156
			 | 
			
			
				+//     done() 
			 | 
		
	
		
			
			| 
				
			 | 
			
				157
			 | 
			
			
				+//   // }) 
			 | 
		
	
		
			
			| 
				
			 | 
			
				158
			 | 
			
			
				+// 
			 | 
		
	
		
			
			| 
				
			 | 
			
				159
			 | 
			
			
				+// }) 
			 | 
		
	
		
			
			| 
				160
			 | 
			
				160
			 | 
			
			
				  
			 | 
		
	
		
			
			| 
				161
			 | 
			
				161
			 | 
			
			
				 // added after 0.5.0 
			 | 
		
	
		
			
			| 
				162
			 | 
			
				162
			 | 
			
			
				  
			 | 
		
	
	
		
			
			| 
				
			 | 
			
			
				@@ -165,21 +165,30 @@ ctx.describe('Get storage folders', (report, done) => { 
			 | 
		
	
		
			
			| 
				165
			 | 
			
				165
			 | 
			
			
				   RNFetchBlob.getSystemDirs().then((dirs) => { 
			 | 
		
	
		
			
			| 
				166
			 | 
			
				166
			 | 
			
			
				     report( 
			 | 
		
	
		
			
			| 
				167
			 | 
			
				167
			 | 
			
			
				       <Assert key="system folders should exists" expect={dirs} comparer={Comparer.exists} />, 
			 | 
		
	
		
			
			| 
				
			 | 
			
				168
			 | 
			
			
				+      <Assert key="check properties" 
			 | 
		
	
		
			
			| 
				
			 | 
			
				169
			 | 
			
			
				+        expect={dirs} 
			 | 
		
	
		
			
			| 
				
			 | 
			
				170
			 | 
			
			
				+        comparer={Comparer.hasProperties} 
			 | 
		
	
		
			
			| 
				
			 | 
			
				171
			 | 
			
			
				+        actual={['PictureDir', 'MovieDir', 'DocumentDir', 'CacheDir']} 
			 | 
		
	
		
			
			| 
				
			 | 
			
				172
			 | 
			
			
				+      />, 
			 | 
		
	
		
			
			| 
				168
			 | 
			
				173
			 | 
			
			
				       <Info key="System Folders"> 
			 | 
		
	
		
			
			| 
				169
			 | 
			
				174
			 | 
			
			
				         <Text>{`${JSON.stringify(dirs)}`}</Text> 
			 | 
		
	
		
			
			| 
				170
			 | 
			
				175
			 | 
			
			
				       </Info> 
			 | 
		
	
		
			
			| 
				171
			 | 
			
				176
			 | 
			
			
				     ) 
			 | 
		
	
		
			
			| 
				
			 | 
			
				177
			 | 
			
			
				+    done() 
			 | 
		
	
		
			
			| 
				172
			 | 
			
				178
			 | 
			
			
				   }) 
			 | 
		
	
		
			
			| 
				173
			 | 
			
				179
			 | 
			
			
				  
			 | 
		
	
		
			
			| 
				174
			 | 
			
				180
			 | 
			
			
				 }) 
			 | 
		
	
		
			
			| 
				175
			 | 
			
				181
			 | 
			
			
				  
			 | 
		
	
		
			
			| 
				176
			 | 
			
				182
			 | 
			
			
				 ctx.describe('Download file to storage', (report, done) => { 
			 | 
		
	
		
			
			| 
				177
			 | 
			
				183
			 | 
			
			
				  
			 | 
		
	
		
			
			| 
				178
			 | 
			
				
			 | 
			
			
				-  RNFetchBlob.config({fileCache : true}) 
			 | 
		
	
		
			
			| 
				
			 | 
			
				184
			 | 
			
			
				+  RNFetchBlob.config({ 
			 | 
		
	
		
			
			| 
				
			 | 
			
				185
			 | 
			
			
				+      fileCache : true, 
			 | 
		
	
		
			
			| 
				
			 | 
			
				186
			 | 
			
			
				+      appendExt : 'png' 
			 | 
		
	
		
			
			| 
				
			 | 
			
				187
			 | 
			
			
				+    }) 
			 | 
		
	
		
			
			| 
				179
			 | 
			
				188
			 | 
			
			
				     .fetch('GET', `${TEST_SERVER_URL}/public/github.png`) 
			 | 
		
	
		
			
			| 
				180
			 | 
			
				189
			 | 
			
			
				     .then((resp) => { 
			 | 
		
	
		
			
			| 
				181
			 | 
			
				190
			 | 
			
			
				       report(<Info key={`image from ${resp.path()}`}> 
			 | 
		
	
		
			
			| 
				182
			 | 
			
				
			 | 
			
			
				-        <Image ssource={{ uri : 'file://' + resp.path()}} style={styles.image}/> 
			 | 
		
	
		
			
			| 
				
			 | 
			
				191
			 | 
			
			
				+        <Image source={{ uri : resp.path()}} style={styles.image}/> 
			 | 
		
	
		
			
			| 
				183
			 | 
			
				192
			 | 
			
			
				       </Info>) 
			 | 
		
	
		
			
			| 
				184
			 | 
			
				193
			 | 
			
			
				       done() 
			 | 
		
	
		
			
			| 
				185
			 | 
			
				194
			 | 
			
			
				     }) 
			 |