diff options
author | Ross Burton <ross.burton@arm.com> | 2024-02-07 16:40:22 +0000 |
---|---|---|
committer | Steve Sakoman <steve@sakoman.com> | 2024-09-21 06:18:58 -0700 |
commit | ff720f337e40761c7d4d544c963cf518ad5403ad (patch) | |
tree | 6c83d99a957769d366fa4192cf353c8a8b820c84 | |
parent | a821a5810ae6edba5882a43e3c60c142f2acda9d (diff) | |
download | openembedded-core-kirkstone.tar.gz |
lib/oeqa: rename assertRaisesRegexp to assertRaisesRegexkirkstone
TestCase.assertRaisesRegexp was renamed to assertRaisesRegex in Python
3.2, so rename to fix a warning during test execution.
Signed-off-by: Ross Burton <ross.burton@arm.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
(cherry picked from commit 6df44a4b29487bf8ef51bb5ba6467a4056b749cc)
Signed-off-by: Steve Sakoman <steve@sakoman.com>
-rw-r--r-- | meta/lib/oeqa/selftest/cases/runcmd.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/meta/lib/oeqa/selftest/cases/runcmd.py b/meta/lib/oeqa/selftest/cases/runcmd.py index e9612389fe..e423fe3d3e 100644 --- a/meta/lib/oeqa/selftest/cases/runcmd.py +++ b/meta/lib/oeqa/selftest/cases/runcmd.py @@ -56,11 +56,11 @@ class RunCmdTests(OESelftestTestCase): self.assertEqual(result.status, 0) def test_result_assertion(self): - self.assertRaisesRegexp(AssertionError, "Command 'echo .* false' returned non-zero exit status 1:\nfoobar", + self.assertRaisesRegex(AssertionError, "Command 'echo .* false' returned non-zero exit status 1:\nfoobar", runCmd, "echo foobar >&2; false", shell=True) def test_result_exception(self): - self.assertRaisesRegexp(CommandError, "Command 'echo .* false' returned non-zero exit status 1 with output: foobar", + self.assertRaisesRegex(CommandError, "Command 'echo .* false' returned non-zero exit status 1 with output: foobar", runCmd, "echo foobar >&2; false", shell=True, assert_error=False) def test_output(self): |