From 6ee0488c6d85ba6d06db55164e194471e2b5898b Mon Sep 17 00:00:00 2001 From: Mark Jansen Date: Wed, 21 Sep 2016 19:26:47 +0000 Subject: [PATCH] [CRT_APITEST] Add tests for __getmainargs, testing a commandline ending with spaces. Patch by Yaroslav Veremenko CORE-9199 svn path=/trunk/; revision=72762 --- rostests/apitests/crt/__getmainargs.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/rostests/apitests/crt/__getmainargs.c b/rostests/apitests/crt/__getmainargs.c index a72ad05a951..b6a23adecc7 100644 --- a/rostests/apitests/crt/__getmainargs.c +++ b/rostests/apitests/crt/__getmainargs.c @@ -84,6 +84,7 @@ START_TEST(__getmainargs) ok_argsA("test.exe a \" b\\ \"\" c", "a", " b\\ \"", "c"); ok_argsA("test.exe a \"b\\ \"\"\" c\" d", "a", "b\\ \" c", "d"); ok_argsA("test.exe a \"b\\ \"\"\" \"c \"\"\"\" d", "a", "b\\ \" c", "\" d"); + ok_argsA("test.exe a b c ", "a", "b", "c"); ok_argsW(L"test.exe \"a b c\" d e", L"a b c", L"d", L"e"); ok_argsW(L"test.exe \"ab\\\"c\" \"\\\\\" d", L"ab\"c", L"\\", L"d"); @@ -97,4 +98,5 @@ START_TEST(__getmainargs) ok_argsW(L"test.exe a \" b\\ \"\" c", L"a", L" b\\ \"", L"c"); ok_argsW(L"test.exe a \"b\\ \"\"\" c\" d", L"a", L"b\\ \" c", L"d"); ok_argsW(L"test.exe a \"b\\ \"\"\" \"c \"\"\"\" d", L"a", L"b\\ \" c", L"\" d"); + ok_argsW(L"test.exe a b c ", L"a", L"b", L"c"); } -- 2.17.1