summaryrefslogtreecommitdiff
path: root/numpy/f2py/tests/test_character.py
diff options
context:
space:
mode:
authorCharles Harris <charlesr.harris@gmail.com>2023-04-21 18:21:05 -0400
committerGitHub <noreply@github.com>2023-04-21 18:21:05 -0400
commit5a49413a6350e957dd35d68edd543a87a9deb1e4 (patch)
tree82f2f701c6a2e5c04441d26820956b00bde873ac /numpy/f2py/tests/test_character.py
parent41b0722d1eaf982adfc2ebc2a4a8ea1f6dfc65d8 (diff)
parent204927f66d2f71da3f4f676769da5684cf85f427 (diff)
downloadnumpy-5a49413a6350e957dd35d68edd543a87a9deb1e4.tar.gz
Merge pull request #23470 from bobeldering/f2py-f77-array-parsing-fix
BUG: Fix bug in parsing F77 style string arrays.
Diffstat (limited to 'numpy/f2py/tests/test_character.py')
-rw-r--r--numpy/f2py/tests/test_character.py22
1 files changed, 12 insertions, 10 deletions
diff --git a/numpy/f2py/tests/test_character.py b/numpy/f2py/tests/test_character.py
index 5f9805158..0bb0f4290 100644
--- a/numpy/f2py/tests/test_character.py
+++ b/numpy/f2py/tests/test_character.py
@@ -576,16 +576,18 @@ class TestStringScalarArr(util.F2PyTest):
@pytest.mark.slow
def test_char(self):
- out = self.module.string_test.string
- expected = ()
- assert out.shape == expected
- expected = '|S8'
- assert out.dtype == expected
+ for out in (self.module.string_test.string,
+ self.module.string_test.string77):
+ expected = ()
+ assert out.shape == expected
+ expected = '|S8'
+ assert out.dtype == expected
@pytest.mark.slow
def test_char_arr(self):
- out = self.module.string_test.strarr
- expected = (5,7)
- assert out.shape == expected
- expected = '|S12'
- assert out.dtype == expected
+ for out in (self.module.string_test.strarr,
+ self.module.string_test.strarr77):
+ expected = (5,7)
+ assert out.shape == expected
+ expected = '|S12'
+ assert out.dtype == expected