From 6914a229a038206341ae1fea46393965a555ca9a Mon Sep 17 00:00:00 2001 From: Andreas Sandberg Date: Tue, 9 May 2017 19:22:53 +0100 Subject: ext: Upgrade PyBind11 to version 2.1.1 Change-Id: I16870dec402d661295f9d013dc23e362b2b2c169 Signed-off-by: Andreas Sandberg Reviewed-by: Curtis Dunham Reviewed-on: https://gem5-review.googlesource.com/3225 Reviewed-by: Jason Lowe-Power --- ext/pybind11/tests/test_alias_initialization.py | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) (limited to 'ext/pybind11/tests/test_alias_initialization.py') diff --git a/ext/pybind11/tests/test_alias_initialization.py b/ext/pybind11/tests/test_alias_initialization.py index 0ed9d2f79..fb90cfc7b 100644 --- a/ext/pybind11/tests/test_alias_initialization.py +++ b/ext/pybind11/tests/test_alias_initialization.py @@ -1,10 +1,11 @@ -import gc +import pytest def test_alias_delay_initialization1(capture): - """A only initializes its trampoline class when we inherit from it; if we just - create and use an A instance directly, the trampoline initialization is bypassed - and we only initialize an A() instead (for performance reasons). + """ + A only initializes its trampoline class when we inherit from it; if we just + create and use an A instance directly, the trampoline initialization is + bypassed and we only initialize an A() instead (for performance reasons). """ from pybind11_tests import A, call_f @@ -20,7 +21,7 @@ def test_alias_delay_initialization1(capture): a = A() call_f(a) del a - gc.collect() + pytest.gc_collect() assert capture == "A.f()" # Python version @@ -28,7 +29,7 @@ def test_alias_delay_initialization1(capture): b = B() call_f(b) del b - gc.collect() + pytest.gc_collect() assert capture == """ PyA.PyA() PyA.f() @@ -57,7 +58,7 @@ def test_alias_delay_initialization2(capture): a2 = A2() call_f(a2) del a2 - gc.collect() + pytest.gc_collect() assert capture == """ PyA2.PyA2() PyA2.f() @@ -70,7 +71,7 @@ def test_alias_delay_initialization2(capture): b2 = B2() call_f(b2) del b2 - gc.collect() + pytest.gc_collect() assert capture == """ PyA2.PyA2() PyA2.f() -- cgit v1.2.3