| 1 | // Licensed to the .NET Foundation under one or more agreements. | 
| 2 | // The .NET Foundation licenses this file to you under the MIT license. | 
| 3 | // See the LICENSE file in the project root for more information. | 
| 4 |  | 
| 5 | /*============================================================================ | 
| 6 | ** | 
| 7 | ** Source:  test12.c | 
| 8 | ** | 
| 9 | ** Purpose: Tests swscanf with wide strings | 
| 10 | ** | 
| 11 | ** | 
| 12 | **==========================================================================*/ | 
| 13 |  | 
| 14 |  | 
| 15 |  | 
| 16 | #include <palsuite.h> | 
| 17 | #include "../swscanf.h" | 
| 18 |  | 
| 19 | int __cdecl main(int argc, char *argv[]) | 
| 20 | { | 
| 21 |     if (PAL_Initialize(argc, argv)) | 
| 22 |     { | 
| 23 |         return FAIL; | 
| 24 |     } | 
| 25 |  | 
| 26 |     DoStrTest(convert("foo bar" ), convert("foo %S" ), "bar" ); | 
| 27 |     DoStrTest(convert("foo bar" ), convert("foo %2S" ), "ba" ); | 
| 28 |     DoStrTest(convert("foo bar" ), convert("foo %hS" ), "bar" ); | 
| 29 |     DoWStrTest(convert("foo bar" ), convert("foo %lS" ), convert("bar" )); | 
| 30 |     DoStrTest(convert("foo bar" ), convert("foo %LS" ), "bar" ); | 
| 31 |     DoStrTest(convert("foo bar" ), convert("foo %I64S" ), "bar" ); | 
| 32 |  | 
| 33 |     PAL_Terminate(); | 
| 34 |     return PASS; | 
| 35 | } | 
| 36 |  |