Skip to content

Commit

Permalink
lab-1: Improve automatic test in Makefile
Browse files Browse the repository at this point in the history
Test the fibonacci function for input = 1 to 100,
  • Loading branch information
Eddy0402 committed Sep 22, 2014
1 parent 38fd546 commit 9fe201b
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions lab-1/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,10 @@ clean:
rm -f $(objects) fibseq

QEMU_CMD = qemu-arm -L /usr/arm-linux-gnueabihf ./fibseq &
CMD = yes 9 | $(call QEMU_CMD) && sleep 1
qemu: fibseq
@yes 5 | $(call QEMU_CMD)
@sleep 1
@yes 6 | $(call QEMU_CMD)
@sleep 1
@yes 7 | $(call QEMU_CMD)
@sleep 1
@test=1 ; while [ $$test -le 100 ] ; do \
yes $$test | $(call QEMU_CMD) \
sleep 1; \
test=`expr $$test + 1`; \
done

0 comments on commit 9fe201b

Please sign in to comment.