aboutsummaryrefslogtreecommitdiffstats
path: root/3rdparty/pybind11/tests/test_copy_move.py
diff options
context:
space:
mode:
authorgatecat <gatecat@ds0.me>2022-09-14 09:28:47 +0200
committergatecat <gatecat@ds0.me>2022-09-14 09:28:47 +0200
commita72f898ff4c4237424c468044a6db9d6953b541e (patch)
tree1c4a543f661dd1b281aecf4660388491702fa8d8 /3rdparty/pybind11/tests/test_copy_move.py
parentf1349e114f3a16ccd002e8513339e18f5be4d31b (diff)
downloadnextpnr-a72f898ff4c4237424c468044a6db9d6953b541e.tar.gz
nextpnr-a72f898ff4c4237424c468044a6db9d6953b541e.tar.bz2
nextpnr-a72f898ff4c4237424c468044a6db9d6953b541e.zip
3rdparty: Bump vendored pybind11 version for py3.11 support
Signed-off-by: gatecat <gatecat@ds0.me>
Diffstat (limited to '3rdparty/pybind11/tests/test_copy_move.py')
-rw-r--r--3rdparty/pybind11/tests/test_copy_move.py13
1 files changed, 10 insertions, 3 deletions
diff --git a/3rdparty/pybind11/tests/test_copy_move.py b/3rdparty/pybind11/tests/test_copy_move.py
index 7e3cc168..9fef0893 100644
--- a/3rdparty/pybind11/tests/test_copy_move.py
+++ b/3rdparty/pybind11/tests/test_copy_move.py
@@ -1,5 +1,5 @@
-# -*- coding: utf-8 -*-
import pytest
+
from pybind11_tests import copy_move_policies as m
@@ -119,7 +119,14 @@ def test_private_op_new():
def test_move_fallback():
"""#389: rvp::move should fall-through to copy on non-movable objects"""
- m2 = m.get_moveissue2(2)
- assert m2.value == 2
m1 = m.get_moveissue1(1)
assert m1.value == 1
+ m2 = m.get_moveissue2(2)
+ assert m2.value == 2
+
+
+def test_pytype_rvalue_cast():
+ """Make sure that cast from pytype rvalue to other pytype works"""
+
+ value = m.get_pytype_rvalue_castissue(1.0)
+ assert value == 1