Added bx::CommandLine test.

This commit is contained in:
Branimir Karadžić
2014-08-07 21:01:19 -07:00
parent 8a9b8e8059
commit 22c812b11e

View File

@@ -5,8 +5,26 @@
#include "test.h"
#include <bx/tokenizecmd.h>
#include <bx/commandline.h>
#include <string.h>
TEST(commandLine)
{
const char* args[] =
{
"-s"
"--long",
};
bx::CommandLine cmdLine(BX_COUNTOF(args), args);
CHECK(NULL != cmdLine.findOption("long") );
CHECK(NULL != cmdLine.findOption('s') );
// non-existing argument
CHECK(NULL == cmdLine.findOption('x') );
}
TEST(tokenizeCommandLine)
{
#if 0