summaryrefslogtreecommitdiffstats
path: root/tests/Utils
diff options
context:
space:
mode:
authorMichal Čihař <michal@cihar.com>2016-09-13 15:06:02 +0200
committerMichal Čihař <michal@cihar.com>2016-09-13 15:06:02 +0200
commit9096eeaa28efae3642c3eb8952a9fe6816f69626 (patch)
tree7fbf1e43e46c5708ec6abd3432316e40d6881934 /tests/Utils
parent0570fa38d50d21e7a96094e5499c435c9814736d (diff)
downloadsql-parser-9096eeaa28efae3642c3eb8952a9fe6816f69626.zip
sql-parser-9096eeaa28efae3642c3eb8952a9fe6816f69626.tar.gz
sql-parser-9096eeaa28efae3642c3eb8952a9fe6816f69626.tar.bz2
Test for invalid output format
Signed-off-by: Michal Čihař <michal@cihar.com>
Diffstat (limited to 'tests/Utils')
-rw-r--r--tests/Utils/CLITest.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/Utils/CLITest.php b/tests/Utils/CLITest.php
index b89cc65..01b1b4d 100644
--- a/tests/Utils/CLITest.php
+++ b/tests/Utils/CLITest.php
@@ -37,6 +37,11 @@ class CLITest extends TestCase
0,
),
array(
+ array('q' => 'SELECT 1', 'f' => 'foo'),
+ "ERROR: Invalid value for format!\n",
+ 1,
+ ),
+ array(
array('q' => 'SELECT 1', 'f' => 'html'),
'<span class="sql-reserved">SELECT</span>' . "\n" .
' <span class="sql-number">1</span>' . "\n",