@@ -159,6 +159,19 @@ namespace TestStringTable
159
159
DESTROY_TABLE (StringTable);
160
160
}
161
161
162
+ TEST_METHOD (TestCreateStringTableFromDelimitedString5)
163
+ {
164
+ PSTRING_TABLE StringTable;
165
+
166
+ STRING Test1 = RTL_CONSTANT_STRING (" foobar;offer;bars;rams;arms;fooz;" );
167
+
168
+ DELIMITED_TABLE (&Test1);
169
+ ASSERT_SIZE (6 );
170
+ DESTROY_TABLE (StringTable);
171
+
172
+ }
173
+
174
+
162
175
//
163
176
// The following is useful when needing to test boundary conditions.
164
177
//
@@ -400,7 +413,7 @@ namespace TestStringTable
400
413
#define DSTFO DEFINE_STRING_TABLE_FUNCTION_OFFSET
401
414
402
415
STRING_TABLE_FUNCTION_OFFSET Functions[] = {
403
- DSTFO (IsPrefixOfStringInTable_x64_12 , TRUE ),
416
+ DSTFO (IsPrefixOfStringInTable_x64_16 , TRUE ),
404
417
// DSTFO(IsPrefixOfStringInTable_13, TRUE)
405
418
};
406
419
@@ -428,5 +441,50 @@ namespace TestStringTable
428
441
Assert::IsTrue (Failed == 0 );
429
442
}
430
443
444
+ TEST_METHOD (TestSubsetHelper2)
445
+ {
446
+ ULONG Failed;
447
+ ULONG Passed;
448
+ BOOLEAN Success;
449
+ PSTRING_ARRAY StringArray;
450
+
451
+ //
452
+ // Change this if you want to quickly test/debug a subset of
453
+ // functions and/or test inputs.
454
+ //
455
+
456
+ STRING_TABLE_TEST_INPUT TestInputs[] = {
457
+ NTFS2_TEST_INPUT (MftMirr1234567890),
458
+ };
459
+
460
+ STRING_TABLE_FUNCTION_OFFSET Functions[] = {
461
+ DSTFO (IsPrefixOfStringInTable_x64_9, TRUE ),
462
+ // DSTFO(IsPrefixOfStringInTable_13, TRUE)
463
+ };
464
+
465
+ // StringArray = (PSTRING_ARRAY)&NtfsStringArray16;
466
+ StringArray = (PSTRING_ARRAY)&Ntfs2StringArray16;
467
+
468
+ Success = Api->TestIsPrefixOfStringInTableFunctions (
469
+ Rtl,
470
+ Allocator,
471
+ Allocator,
472
+ StringArray,
473
+ (PSTRING_TABLE_ANY_API)Api,
474
+ sizeof (*Api),
475
+ (PCSTRING_TABLE_FUNCTION_OFFSET)&Functions,
476
+ ARRAYSIZE (Functions),
477
+ (PCSTRING_TABLE_TEST_INPUT)&TestInputs,
478
+ ARRAYSIZE (TestInputs),
479
+ TRUE ,
480
+ TRUE ,
481
+ &Failed,
482
+ &Passed
483
+ );
484
+
485
+ Assert::IsTrue (Success);
486
+ Assert::IsTrue (Failed == 0 );
487
+ }
488
+
431
489
};
432
490
}
0 commit comments