Ensure parallel test works properly.
authorPaul Smith <psmith@gnu.org>
Sun, 13 Jan 2013 02:54:41 +0000 (21:54 -0500)
committerPaul Smith <psmith@gnu.org>
Sun, 13 Jan 2013 02:54:41 +0000 (21:54 -0500)
tests/scripts/features/parallelism

index 08c822e37664c1c5106cde4dfeb731696a27c487..a8955174031febb555fe0700339788a88f208798 100644 (file)
@@ -91,12 +91,12 @@ run_make_test("
 all: fail.1 ok fail.2 fail.3
 
 fail.1 fail.2 fail.3:
-       \@sleep \$(patsubst fail.%,%,\$\@)
+       \@$sleep_command \$(patsubst fail.%,%,\$\@)
        \@echo Fail
        \@exit 1
 
 ok:
-       \@sleep 4
+       \@$sleep_command 4
        \@echo Ok done",
               '-rR -j5', "Fail
 #MAKEFILE#:6: recipe for target 'fail.1' failed
@@ -175,11 +175,12 @@ $extraENV{MAKEFLAGS} = '-j4';
 run_make_test(q!
 things = thing1 thing2
 all: $(things)
-$(things):; @echo '$@ start'; sleep 1; echo '$@ end'
+thing1:; @sleep 1; echo '$@ start'; sleep 2; echo '$@ end'
+thing2:; @echo '$@ start'; sleep 2; echo '$@ end'
 -include inc.mk
 inc.mk: ; @touch $@
 !,
-              '', "thing1 start\nthing2 start\nthing1 end\nthing2 end\n");
+              '', "thing2 start\nthing1 start\nthing2 end\nthing1 end\n");
 
 delete $extraENV{MAKEFLAGS};
 rmfiles('inc.mk');