@@ -6,13 +6,17 @@ def test_pkginfo_to_metadata(tmpdir):
6
6
('Metadata-Version' , '2.1' ),
7
7
('Name' , 'spam' ),
8
8
('Version' , '0.1' ),
9
- ('Provides-Extra ' , 'test ' ),
9
+ ('Requires-Dist ' , 'pywin32; sys_platform=="win32" ' ),
10
10
('Provides-Extra' , 'signatures' ),
11
+ ('Requires-Dist' , 'pyxdg; (sys_platform!="win32") and extra == \' signatures\' ' ),
12
+ ('Provides-Extra' , 'empty_extra' ),
11
13
('Provides-Extra' , 'faster-signatures' ),
12
14
('Requires-Dist' , "ed25519ll; extra == 'faster-signatures'" ),
15
+ ('Provides-Extra' , 'rest' ),
16
+ ('Requires-Dist' , "docutils (>=0.8); extra == 'rest'" ),
13
17
('Requires-Dist' , "keyring; extra == 'signatures'" ),
14
18
('Requires-Dist' , "keyrings.alt; extra == 'signatures'" ),
15
- ('Requires-Dist ' , 'pyxdg; (sys_platform!="win32") and extra == \' signatures \' ' ),
19
+ ('Provides-Extra ' , 'test ' ),
16
20
('Requires-Dist' , "pytest (>=3.0.0); extra == 'test'" ),
17
21
('Requires-Dist' , "pytest-cov; extra == 'test'" ),
18
22
]
@@ -22,20 +26,31 @@ def test_pkginfo_to_metadata(tmpdir):
22
26
Metadata-Version: 0.0
23
27
Name: spam
24
28
Version: 0.1
29
+ Provides-Extra: empty+extra
25
30
Provides-Extra: test
31
+ Provides-Extra: reST
26
32
Provides-Extra: signatures
33
+ Provides-Extra: Signatures
27
34
Provides-Extra: faster-signatures""" )
28
35
29
36
egg_info_dir = tmpdir .ensure_dir ('test.egg-info' )
30
37
egg_info_dir .join ('requires.txt' ).write ("""\
38
+ [empty+extra]
39
+
40
+ [:sys_platform=="win32"]
41
+ pywin32
42
+
31
43
[faster-signatures]
32
44
ed25519ll
33
45
46
+ [reST]
47
+ docutils>=0.8
48
+
34
49
[signatures]
35
50
keyring
36
51
keyrings.alt
37
52
38
- [signatures :sys_platform!="win32"]
53
+ [Signatures :sys_platform!="win32"]
39
54
pyxdg
40
55
41
56
[test]
0 commit comments