|
@@ -14,7 +14,7 @@ class TestKickassEngine(SearxTestCase):
|
14
|
14
|
params = kickass.request(query, dicto)
|
15
|
15
|
self.assertIn('url', params)
|
16
|
16
|
self.assertIn(query, params['url'])
|
17
|
|
- self.assertIn('kickass.to', params['url'])
|
|
17
|
+ self.assertIn('kickass.cd', params['url'])
|
18
|
18
|
self.assertFalse(params['verify'])
|
19
|
19
|
|
20
|
20
|
def test_response(self):
|
|
@@ -84,7 +84,7 @@ class TestKickassEngine(SearxTestCase):
|
84
|
84
|
</span>
|
85
|
85
|
</div>
|
86
|
86
|
</td>
|
87
|
|
- <td class="nobr center">449 <span>bytes</span></td>
|
|
87
|
+ <td class="nobr center">449 bytes</td>
|
88
|
88
|
<td class="center">4</td>
|
89
|
89
|
<td class="center">2 years</td>
|
90
|
90
|
<td class="green center">10</td>
|
|
@@ -97,7 +97,7 @@ class TestKickassEngine(SearxTestCase):
|
97
|
97
|
self.assertEqual(type(results), list)
|
98
|
98
|
self.assertEqual(len(results), 1)
|
99
|
99
|
self.assertEqual(results[0]['title'], 'This should be the title')
|
100
|
|
- self.assertEqual(results[0]['url'], 'https://kickass.to/url.html')
|
|
100
|
+ self.assertEqual(results[0]['url'], 'https://kickass.cd/url.html')
|
101
|
101
|
self.assertEqual(results[0]['content'], 'Posted by riri in Other > Unsorted')
|
102
|
102
|
self.assertEqual(results[0]['seed'], 10)
|
103
|
103
|
self.assertEqual(results[0]['leech'], 1)
|
|
@@ -191,7 +191,7 @@ class TestKickassEngine(SearxTestCase):
|
191
|
191
|
</span>
|
192
|
192
|
</div>
|
193
|
193
|
</td>
|
194
|
|
- <td class="nobr center">1 <span>KB</span></td>
|
|
194
|
+ <td class="nobr center">1 KiB</td>
|
195
|
195
|
<td class="center">4</td>
|
196
|
196
|
<td class="center">2 years</td>
|
197
|
197
|
<td class="green center">10</td>
|
|
@@ -235,7 +235,7 @@ class TestKickassEngine(SearxTestCase):
|
235
|
235
|
</span>
|
236
|
236
|
</div>
|
237
|
237
|
</td>
|
238
|
|
- <td class="nobr center">1 <span>MB</span></td>
|
|
238
|
+ <td class="nobr center">1 MiB</td>
|
239
|
239
|
<td class="center">4</td>
|
240
|
240
|
<td class="center">2 years</td>
|
241
|
241
|
<td class="green center">9</td>
|
|
@@ -279,7 +279,7 @@ class TestKickassEngine(SearxTestCase):
|
279
|
279
|
</span>
|
280
|
280
|
</div>
|
281
|
281
|
</td>
|
282
|
|
- <td class="nobr center">1 <span>GB</span></td>
|
|
282
|
+ <td class="nobr center">1 GiB</td>
|
283
|
283
|
<td class="center">4</td>
|
284
|
284
|
<td class="center">2 years</td>
|
285
|
285
|
<td class="green center">8</td>
|
|
@@ -323,7 +323,7 @@ class TestKickassEngine(SearxTestCase):
|
323
|
323
|
</span>
|
324
|
324
|
</div>
|
325
|
325
|
</td>
|
326
|
|
- <td class="nobr center">1 <span>TB</span></td>
|
|
326
|
+ <td class="nobr center">1 TiB</td>
|
327
|
327
|
<td class="center">4</td>
|
328
|
328
|
<td class="center">2 years</td>
|
329
|
329
|
<td class="green center">7</td>
|
|
@@ -367,7 +367,7 @@ class TestKickassEngine(SearxTestCase):
|
367
|
367
|
</span>
|
368
|
368
|
</div>
|
369
|
369
|
</td>
|
370
|
|
- <td class="nobr center">z <span>bytes</span></td>
|
|
370
|
+ <td class="nobr center">z bytes</td>
|
371
|
371
|
<td class="center">r</td>
|
372
|
372
|
<td class="center">2 years</td>
|
373
|
373
|
<td class="green center">a</td>
|
|
@@ -380,17 +380,17 @@ class TestKickassEngine(SearxTestCase):
|
380
|
380
|
self.assertEqual(type(results), list)
|
381
|
381
|
self.assertEqual(len(results), 5)
|
382
|
382
|
self.assertEqual(results[0]['title'], 'This should be the title')
|
383
|
|
- self.assertEqual(results[0]['url'], 'https://kickass.to/url.html')
|
|
383
|
+ self.assertEqual(results[0]['url'], 'https://kickass.cd/url.html')
|
384
|
384
|
self.assertEqual(results[0]['content'], 'Posted by riri in Other > Unsorted')
|
385
|
385
|
self.assertEqual(results[0]['seed'], 10)
|
386
|
386
|
self.assertEqual(results[0]['leech'], 1)
|
387
|
387
|
self.assertEqual(results[0]['files'], 4)
|
388
|
388
|
self.assertEqual(results[0]['magnetlink'], 'magnet:?xt=urn:btih:MAGNETURL&dn=test')
|
389
|
389
|
self.assertEqual(results[0]['torrentfile'], 'http://torcache.net/torrent/53917.torrent?title=test')
|
390
|
|
- self.assertEqual(results[0]['filesize'], 1024)
|
391
|
|
- self.assertEqual(results[1]['filesize'], 1048576)
|
392
|
|
- self.assertEqual(results[2]['filesize'], 1073741824)
|
393
|
|
- self.assertEqual(results[3]['filesize'], 1099511627776)
|
|
390
|
+ self.assertEqual(results[0]['filesize'], 1000)
|
|
391
|
+ self.assertEqual(results[1]['filesize'], 1000000)
|
|
392
|
+ self.assertEqual(results[2]['filesize'], 1000000000)
|
|
393
|
+ self.assertEqual(results[3]['filesize'], 1000000000000)
|
394
|
394
|
self.assertEqual(results[4]['seed'], 0)
|
395
|
395
|
self.assertEqual(results[4]['leech'], 0)
|
396
|
396
|
self.assertEqual(results[4]['files'], None)
|