From 41c0db3ce91782f4ce766850fbe98f6d9d6c487d Mon Sep 17 00:00:00 2001 From: Trey Hunner Date: Thu, 18 Feb 2010 21:39:32 -0800 Subject: [PATCH] cmd: Add test for 'if' case sensitivity. --- programs/cmd/tests/test_builtins.cmd | 7 +++++++ programs/cmd/tests/test_builtins.cmd.exp | 4 ++++ 2 files changed, 11 insertions(+) diff --git a/programs/cmd/tests/test_builtins.cmd b/programs/cmd/tests/test_builtins.cmd index 317fbdd6bfe..ed2b75bdc88 100644 --- a/programs/cmd/tests/test_builtins.cmd +++ b/programs/cmd/tests/test_builtins.cmd @@ -36,3 +36,10 @@ if 1 == 0 ( ) else ( echo else seems to work ) +echo Testing case sensitivity with and without /i option +if bar==BAR echo if does not default to case sensitivity +if not bar==BAR echo if seems to default to case sensitivity +if /i foo==FOO echo if /i seems to work +if /i not foo==FOO echo if /i seems to be broken +if /I foo==FOO echo if /I seems to work +if /I not foo==FOO echo if /I seems to be broken diff --git a/programs/cmd/tests/test_builtins.cmd.exp b/programs/cmd/tests/test_builtins.cmd.exp index c53aa1ff7c4..2c0e9803d30 100644 --- a/programs/cmd/tests/test_builtins.cmd.exp +++ b/programs/cmd/tests/test_builtins.cmd.exp @@ -20,3 +20,7 @@ bar if/else should work with blocks if seems to work else seems to work +Testing case sensitivity with and without /i option +if seems to default to case sensitivity +if /i seems to work +if /I seems to work