GNU do: invert subprocess success?

I have a makefile for a scripting system with a lot of tests that must pass. Each test is a separate scripting application call:

#----------------------------------------------------------------------------
# run test scripts in the module::test
#----------------------------------------------------------------------------
scripted_tests: bin/kin modules/test/actor_equality.kin modules/test/actor_fibre.kin ...
    bin/kin modules/test/actor_equality.kin
    bin/kin modules/test/actor_fibre.kin
    ...

This is normal. I also have some similar tests that should return failure. I know that I -will ignore the return status, but there must be something simple to invert the return status so that I can run

#----------------------------------------------------------------------------
# run test scripts in the module::test::errors
#----------------------------------------------------------------------------
inverse_tests: bin/kin modules/test/error/bad_function.kin ...
    not bin/kin modules/test/error/bad_function.kin
    ...
+5
source share
2 answers

Use the command !.

echo This returns success
! echo This returns failure
+8
source

, , "bin/kin test5.kin" 5. :

run-test5:
  bin/kin test5.bin; test $$? = 5

. "test test" "man test".

. , , , / ( ).

+1

All Articles