summaryrefslogtreecommitdiffstats
path: root/scripts/patchtest.README
diff options
context:
space:
mode:
authorTrevor Gamblin <tgamblin@baylibre.com>2023-10-16 15:44:58 -0400
committerRichard Purdie <richard.purdie@linuxfoundation.org>2023-10-17 11:41:34 +0100
commit26e3d58e71e5a88ac2c2d34845f45c77635cd2d4 (patch)
treea5e2359080ee9efa58bfd2ebb2fc88751ce03232 /scripts/patchtest.README
parent6e53a778f10c77eab3c0172a0cbc4d63efc663e9 (diff)
downloadpoky-26e3d58e71e5a88ac2c2d34845f45c77635cd2d4.tar.gz
patchtest: set default repo and testdir targets
Since patchtest is in oe-core, the Python os module's methods can be used to retrieve the repository path and tests directory by default. This reduces the number of mandatory arguments for invocation of patchtest unless the user wants to use a custom test suite or test patches against a different repo. The REPO and TESTDIR arguments are likewise adjusted so that they are optional. Also, make it more obvious what the --startdir flag is meant for on the command line by renaming it to --testdir, and update the scripts/patchtest.README file to be consistent with the new usage. (From OE-Core rev: bae7421ece4806f5148f164293810b9fe75e0756) Signed-off-by: Trevor Gamblin <tgamblin@baylibre.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts/patchtest.README')
-rw-r--r--scripts/patchtest.README10
1 files changed, 7 insertions, 3 deletions
diff --git a/scripts/patchtest.README b/scripts/patchtest.README
index 689d513df5..ad46b02ad6 100644
--- a/scripts/patchtest.README
+++ b/scripts/patchtest.README
@@ -79,15 +79,19 @@ To run patchtest on the host, do the following:
79 or patchtest-get-series 79 or patchtest-get-series
803. Run patchtest on a patch file by doing the following: 803. Run patchtest on a patch file by doing the following:
81 81
82 patchtest --patch /path/to/patch/file /path/to/target/repo /path/to/tests/directory 82 patchtest --patch /path/to/patch/file
83 83
84 or, if you have stored the patch files in a directory, do: 84 or, if you have stored the patch files in a directory, do:
85 85
86 patchtest --directory /path/to/patch/directory /path/to/target/repo /path/to/tests/directory 86 patchtest --directory /path/to/patch/directory
87 87
88 For example, to test `master-gcc-Fix--fstack-protector-issue-on-aarch64.patch` against the oe-core test suite: 88 For example, to test `master-gcc-Fix--fstack-protector-issue-on-aarch64.patch` against the oe-core test suite:
89 89
90 patchtest --patch master-gcc-Fix--fstack-protector-issue-on-aarch64.patch /path/to/openembedded-core /path/to/openembedded-core/meta/lib/patchtest/tests 90 patchtest --patch master-gcc-Fix--fstack-protector-issue-on-aarch64.patch
91
92 If you want to use a different test suite or target repository, you can use the --testdir and --repodir flags:
93
94 patchtest --patch /path/to/patch/file --repodir /path/to/repo --testdir /path/to/test/dir
91 95
92### Guest Mode 96### Guest Mode
93 97