File tree 5 files changed +5
-8
lines changed
5 files changed +5
-8
lines changed Original file line number Diff line number Diff line change 14
14
- name : Install dependencies
15
15
run : |
16
16
python -m pip install --upgrade pip
17
- python -m pip install gevent requests pytest nose
17
+ python -m pip install gevent requests pytest
18
18
- name : Test with pytest
19
19
run : |
20
20
pytest tests.py
Original file line number Diff line number Diff line change 1
1
.coverage
2
2
MANIFEST
3
3
coverage.xml
4
- nosetests.xml
5
4
junit-report.xml
6
5
pylint.txt
7
6
toy.py
Original file line number Diff line number Diff line change 1
1
requests
2
2
gevent
3
- nose
3
+ pytest
Original file line number Diff line number Diff line change 44
44
'gevent' ,
45
45
'requests'
46
46
],
47
- tests_require = ['nose' ],
48
- test_suite = 'nose.collector' ,
47
+ tests_require = ['pytest' ],
49
48
py_modules = ['grequests' ],
50
49
zip_safe = False ,
51
50
include_package_data = True ,
Original file line number Diff line number Diff line change 2
2
# -*- coding: utf-8 -*-
3
3
4
4
from grequests import get , map , imap
5
- from nose .tools import ok_
6
5
7
6
########### Constants ############
8
7
urls = [
@@ -16,14 +15,14 @@ def test_get():
16
15
to_fetch = (get (url ) for url in urls )
17
16
map (to_fetch )
18
17
for fetched in to_fetch :
19
- ok_ ( fetched .ok , True )
18
+ assert fetched .ok
20
19
21
20
def test_imap_with_size ():
22
21
global urls
23
22
to_fetch = (get (url ) for url in urls )
24
23
imap (to_fetch , size = len (urls ) - 1 )
25
24
for fetching in to_fetch :
26
- ok_ ( fetching .send (), True )
25
+ assert fetching .send ()
27
26
28
27
import os
29
28
import time
You can’t perform that action at this time.
0 commit comments