diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/ChangeLog | 4 | ||||
-rw-r--r-- | tests/scripts/functions/flavor | 44 |
2 files changed, 48 insertions, 0 deletions
diff --git a/tests/ChangeLog b/tests/ChangeLog index d30f0c9..01aecc6 100644 --- a/tests/ChangeLog +++ b/tests/ChangeLog @@ -1,3 +1,7 @@ +2005-11-17 Boris Kolpackov <boris@kolpackov.net> + + * scripts/functions/flavor: Add a test for the flavor function. + 2005-11-14 Boris Kolpackov <boris@kolpackov.net> * scripts/variables/INCLUDE_DIRS: Add a test for the .INCLUDE_DIRS diff --git a/tests/scripts/functions/flavor b/tests/scripts/functions/flavor new file mode 100644 index 0000000..80d6be7 --- /dev/null +++ b/tests/scripts/functions/flavor @@ -0,0 +1,44 @@ +# -*-perl-*- +$description = "Test the flavor function."; + +$details = ""; + + +# Test #1: Test general logic. +# +run_make_test(' +s := s +r = r + +$(info u $(flavor u)) +$(info s $(flavor s)) +$(info r $(flavor r)) + +ra += ra +rc ?= rc + +$(info ra $(flavor ra)) +$(info rc $(flavor rc)) + +s += s +r += r + +$(info s $(flavor s)) +$(info r $(flavor r)) + + +.PHONY: all +all:;@: +', +'', +'u undefined +s simple +r recursive +ra recursive +rc recursive +s simple +r recursive'); + + +# This tells the test driver that the perl test script executed properly. +1; |