Author: Carl Friedrich Bolz-Tereick <[email protected]>
Branch: 
Changeset: r98569:075c10ca9276
Date: 2020-01-22 14:12 +0100
http://bitbucket.org/pypy/pypy/changeset/075c10ca9276/

Log:    be more precise about test_error_message_module_function: it's
        checking for the absence of something at the end

diff --git a/pypy/interpreter/test/test_argument.py 
b/pypy/interpreter/test/test_argument.py
--- a/pypy/interpreter/test/test_argument.py
+++ b/pypy/interpreter/test/test_argument.py
@@ -763,7 +763,8 @@
         import operator # use repeat because it's defined at applevel
         exc = raises(TypeError, lambda : operator.repeat(1, 2, 3))
         # does not contain the warning about missing self
-        assert "takes exactly 2 arguments (3 given)" in str(exc.value)
+        # in particular it must not end with ' Did you forget 'self' in the 
function definition?'
+        assert str(exc.value).endswith("takes exactly 2 arguments (3 given)")
 
     @pytest.mark.pypy_only
     def test_error_message_bound_method(self):
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to