unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
blob 0a80d15cd285da88c27db716dae668bc7128c830 3851 bytes (raw)
name: gnu/packages/patches/python-shouldbe-0.1.2-cpy3.8.patch 	 # note: path name is non-authoritative(*)

 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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
 
diff -x '*.pyc' -Naur shouldbe-0.1.2/should_be/core.py shouldbe-0.1.2.patched/should_be/core.py
--- shouldbe-0.1.2/should_be/core.py	2019-03-06 07:38:22.000000000 +0100
+++ shouldbe-0.1.2.patched/should_be/core.py	2020-05-18 08:44:24.214664704 +0200
@@ -103,7 +103,7 @@
     return resf
 
 
-def buildCode(baseCode, argcount=None, kwonlyargcount=None,
+def buildCode(baseCode, argcount=None, posonlyargcount=None, kwonlyargcount=None,
               nlocals=None, stacksize=None, flags=None,
               code=None, consts=None, names=None,
               varnames=None, filename=None, name=None,
@@ -121,6 +121,24 @@
                         nlocals or baseCode.co_nlocals,
                         stacksize or baseCode.co_stacksize,
                         flags or baseCode.co_flags,
+                        code or baseCode.co_code,
+                        consts or baseCode.co_consts,
+                        names or baseCode.co_names,
+                        varnames or baseCode.co_varnames,
+                        filename or baseCode.co_filename,
+                        name or baseCode.co_name,
+                        firstlineno or baseCode.co_firstlineno,
+                        lnotab or baseCode.co_lnotab,
+                        freevars or baseCode.co_freevars,
+                        cellvars or baseCode.co_cellvars)
+    elif hasattr(baseCode, 'co_posonlyargcount'):
+        # Python 3.8
+        resc = CodeType(argcount or baseCode.co_argcount,
+                        posonlyargcount or baseCode.co_posonlyargcount,
+                        kwonlyargcount or baseCode.co_kwonlyargcount,
+                        nlocals or baseCode.co_nlocals,
+                        stacksize or baseCode.co_stacksize,
+                        flags or baseCode.co_flags,
                         code or baseCode.co_code,
                         consts or baseCode.co_consts,
                         names or baseCode.co_names,
diff -x '*.pyc' -Naur shouldbe-0.1.2/should_be/tests/test_container_mixin.py shouldbe-0.1.2.patched/should_be/tests/test_container_mixin.py
--- shouldbe-0.1.2/should_be/tests/test_container_mixin.py	2019-03-01 06:38:16.000000000 +0100
+++ shouldbe-0.1.2.patched/should_be/tests/test_container_mixin.py	2020-05-18 09:00:51.372531064 +0200
@@ -7,31 +7,31 @@
         self.lst = [1, 2, 3]
 
     def test_should_include_iter(self):
-        err_msg = (r'[a-zA-Z0-9.]+ should have included \[.+?\]'
+        err_msg = (r'[a-zA-Z0-9.()]+ should have included \[.+?\]'
                    r', but did not have items .+')
-        self.assertRaisesRegexp(AssertionError, err_msg,
+        self.assertRaisesRegex(AssertionError, err_msg,
                                 self.lst.should_include, [4])
 
         self.lst.should_include([1, 2, 3])
 
     def test_should_include_item(self):
-        err_msg = (r'[a-zA-Z0-9.]+ should have included .+?'
+        err_msg = (r'[a-zA-Z0-9.()]+ should have included .+?'
                    r', but did not')
-        self.assertRaisesRegexp(AssertionError, err_msg,
+        self.assertRaisesRegex(AssertionError, err_msg,
                                 self.lst.should_include, 4)
 
         self.lst.should_include(3)
 
     def test_shouldnt_include_iter(self):
         err_msg = 'should not have included'
-        self.assertRaisesRegexp(AssertionError, err_msg,
+        self.assertRaisesRegex(AssertionError, err_msg,
                                 self.lst.shouldnt_include, [2, 3])
 
         self.lst.shouldnt_include([4, 5])
 
     def test_shouldnt_include_item(self):
         err_msg = 'should not have included'
-        self.assertRaisesRegexp(AssertionError, err_msg,
+        self.assertRaisesRegex(AssertionError, err_msg,
                                 self.lst.shouldnt_include, 3)
 
         self.lst.shouldnt_include(4)

debug log:

solving 0a80d15cd2 ...
found 0a80d15cd2 in https://yhetil.org/guix-patches/20200519074649.GA11910@zpidnp36/

applying [1/1] https://yhetil.org/guix-patches/20200519074649.GA11910@zpidnp36/
diff --git a/gnu/packages/patches/python-shouldbe-0.1.2-cpy3.8.patch b/gnu/packages/patches/python-shouldbe-0.1.2-cpy3.8.patch
new file mode 100644
index 0000000000..0a80d15cd2

1:12: trailing whitespace.
 
1:13: trailing whitespace.
 
1:49: trailing whitespace.
 
1:57: trailing whitespace.
 
1:59: trailing whitespace.
 
Checking patch gnu/packages/patches/python-shouldbe-0.1.2-cpy3.8.patch...
Applied patch gnu/packages/patches/python-shouldbe-0.1.2-cpy3.8.patch cleanly.
warning: squelched 5 whitespace errors
warning: 10 lines add whitespace errors.

index at:
100644 0a80d15cd285da88c27db716dae668bc7128c830	gnu/packages/patches/python-shouldbe-0.1.2-cpy3.8.patch

(*) Git path names are given by the tree(s) the blob belongs to.
    Blobs themselves have no identifier aside from the hash of its contents.^

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).