diff options
author | Armin Rigo <arigo@tunes.org> | 2019-04-02 16:47:56 +0200 |
---|---|---|
committer | Armin Rigo <arigo@tunes.org> | 2019-04-02 16:47:56 +0200 |
commit | d62f286d2f621fbc7dbe1a5f666e3337c084e3e1 (patch) | |
tree | 2cce464e742e2b887ce0d25bdd85735eb048dfd6 | |
parent | 22887ae7ec10a217b0267ea8a6106ec3b8dd44b3 (diff) | |
download | cffi-d62f286d2f621fbc7dbe1a5f666e3337c084e3e1.tar.gz |
Two more cases
-rw-r--r-- | c/test_c.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/c/test_c.py b/c/test_c.py index 4aec6ae..9f30b76 100644 --- a/c/test_c.py +++ b/c/test_c.py @@ -4363,3 +4363,7 @@ def test_int_doesnt_give_bool(): assert type(x) is int and x == 1 x = long(cast(BBool, 42)) assert type(x) is long and x == 1 + with pytest.raises(TypeError): + float(cast(BBool, 42)) + with pytest.raises(TypeError): + complex(cast(BBool, 42)) |