You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Document how to use assert_cmd with rust-cross #139
It would be nice to mention that when running tests in cross, one needs to prepend their command with the value contained in CARGO_TARGET_*_RUNNER i.e qemu-aarch64 xh
I wonder, has this changed at all? I'm struggling to get my integration tests running with cross v0.2.4 and assert_cmd.
When running under cross for --target armv7-unknown-linux-gnueabihf, CARGO_TARGET_ARMV7_UNKNOWN_LINUX_GNUEABIHF_RUNNER = /linux-runner armv7 i.e. the value does not contain qemu, which is what is tested for in find_runner().
Experimenting with adding the prefix manually, the following do not work: /linux-runner armv7, qemu-armv7 and qemu-aarch64.
What does work is qemu-arm, but that is nowhere to be found in the environment variables.
Hence I ask, what is the best way to handle this case at present?
Activity
epage commentedon Dec 22, 2021
Thanks for providing an example on how to do this. This will be good to add to the docs here and for trycmd
mfreeborn commentedon Jul 30, 2022
I wonder, has this changed at all? I'm struggling to get my integration tests running with
crossv0.2.4 andassert_cmd.When running under cross for
--target armv7-unknown-linux-gnueabihf,CARGO_TARGET_ARMV7_UNKNOWN_LINUX_GNUEABIHF_RUNNER=/linux-runner armv7i.e. the value does not containqemu, which is what is tested for infind_runner().Experimenting with adding the prefix manually, the following do not work:
/linux-runner armv7,qemu-armv7andqemu-aarch64.What does work is
qemu-arm, but that is nowhere to be found in the environment variables.Hence I ask, what is the best way to handle this case at present?
ducaale commentedon Jul 30, 2022
@mfreeborn, can you try if the following works for you? I think the values of
CARGO_TARGET_*_RUNNERhave been updated in cross v0.2.2mfreeborn commentedon Jul 30, 2022
I can confirm that is working - thanks very much!
mizuki0629 commentedon Dec 16, 2023
Thank you for helping me find this method. Please document it for future reference.
document the runner configuration usage
feat: add cargo runner support in order to work with cross
feat: add cargo runner support in order to work with cross
feat: add cargo runner support in order to work with cross
feat: add cargo runner support in order to work with cross