37static const char msifile[] =
"winetest-package.msi";
56#define GET_PROC(mod, func) \
57 p ## func = (void*)GetProcAddress(mod, #func);
82 trace(
"Could not check if the current user is an administrator\n");
93 0, 0, 0, 0, 0, 0, &
Group) ||
96 trace(
"Could not check if the current user is a power user\n");
121 if (pRegDeleteKeyExA)
122 return pRegDeleteKeyExA(
key, subkey,
access, 0 );
131 char *usersid =
NULL;
149 DWORD dwMaxSubkeyLen, dwMaxValueLen;
166 dwMaxLen =
max(dwMaxSubkeyLen, dwMaxValueLen);
170 if (!(lpszName =
malloc(dwMaxLen *
sizeof(
WCHAR))))
190 if (pRegDeleteKeyExW)
207 if (lpszName != szNameBuf)
free(lpszName);
253 ok(
hr ==
S_OK,
"Expected S_OK, got %#lx\n",
hr);
256 ok(
size == 39,
"Expected 39, got %#lx\n",
hr);
285 prod =
"3D0DAE300FACA1300AD792060BCDAA92";
287 "SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\"
288 "Installer\\UserData\\S-1-5-18\\Components\\%s", squashed);
290 "SOFTWARE\\Classes\\Installer\\"
291 "Products\\3D0DAE300FACA1300AD792060BCDAA92");
295 prod =
"7D2F387510109040002000060BECB6AB";
297 "SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\"
298 "Installer\\UserData\\%s\\Components\\%s", usersid, squashed);
300 "SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\"
301 "Installer\\%s\\Installer\\Products\\"
302 "7D2F387510109040002000060BECB6AB", usersid);
306 prod =
"7D2F387510109040002000060BECB6AB";
308 "SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\"
309 "Installer\\UserData\\%s\\Components\\%s", usersid, squashed);
311 "SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\"
312 "Installer\\Managed\\%s\\Installer\\Products\\"
313 "7D2F387510109040002000060BECB6AB", usersid);
349 "SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\"
350 "Installer\\UserData\\S-1-5-18\\Components\\%s", squashed);
352 "SOFTWARE\\Classes\\Installer\\"
353 "Products\\3D0DAE300FACA1300AD792060BCDAA92");
358 "SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\"
359 "Installer\\UserData\\%s\\Components\\%s", usersid, squashed);
361 "SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\"
362 "Installer\\%s\\Installer\\Products\\"
363 "7D2F387510109040002000060BECB6AB", usersid);
368 "SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\"
369 "Installer\\UserData\\%s\\Components\\%s", usersid, squashed);
371 "SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\"
372 "Installer\\Managed\\%s\\Installer\\Products\\"
373 "7D2F387510109040002000060BECB6AB", usersid);
424 "CREATE TABLE `Component` ( "
425 "`Component` CHAR(72) NOT NULL, "
426 "`ComponentId` CHAR(38), "
427 "`Directory_` CHAR(72) NOT NULL, "
428 "`Attributes` SHORT NOT NULL, "
429 "`Condition` CHAR(255), "
430 "`KeyPath` CHAR(72) "
431 "PRIMARY KEY `Component`)" );
439 "CREATE TABLE `Feature` ( "
440 "`Feature` CHAR(38) NOT NULL, "
441 "`Feature_Parent` CHAR(38), "
443 "`Description` CHAR(255), "
444 "`Display` SHORT NOT NULL, "
445 "`Level` SHORT NOT NULL, "
446 "`Directory_` CHAR(72), "
447 "`Attributes` SHORT NOT NULL "
448 "PRIMARY KEY `Feature`)" );
456 "CREATE TABLE `FeatureComponents` ( "
457 "`Feature_` CHAR(38) NOT NULL, "
458 "`Component_` CHAR(72) NOT NULL "
459 "PRIMARY KEY `Feature_`, `Component_` )" );
467 "CREATE TABLE `File` ("
468 "`File` CHAR(72) NOT NULL, "
469 "`Component_` CHAR(72) NOT NULL, "
470 "`FileName` CHAR(255) NOT NULL, "
471 "`FileSize` LONG NOT NULL, "
472 "`Version` CHAR(72), "
473 "`Language` CHAR(20), "
474 "`Attributes` SHORT, "
475 "`Sequence` SHORT NOT NULL "
476 "PRIMARY KEY `File`)" );
484 "CREATE TABLE `RemoveFile` ("
485 "`FileKey` CHAR(72) NOT NULL, "
486 "`Component_` CHAR(72) NOT NULL, "
487 "`FileName` CHAR(255) LOCALIZABLE, "
488 "`DirProperty` CHAR(72) NOT NULL, "
489 "`InstallMode` SHORT NOT NULL "
490 "PRIMARY KEY `FileKey`)" );
498 "CREATE TABLE `AppSearch` ("
499 "`Property` CHAR(72) NOT NULL, "
500 "`Signature_` CHAR(72) NOT NULL "
501 "PRIMARY KEY `Property`, `Signature_`)" );
509 "CREATE TABLE `RegLocator` ("
510 "`Signature_` CHAR(72) NOT NULL, "
511 "`Root` SHORT NOT NULL, "
512 "`Key` CHAR(255) NOT NULL, "
515 "PRIMARY KEY `Signature_`)" );
523 "CREATE TABLE `Signature` ("
524 "`Signature` CHAR(72) NOT NULL, "
525 "`FileName` CHAR(255) NOT NULL, "
526 "`MinVersion` CHAR(20), "
527 "`MaxVersion` CHAR(20), "
532 "`Languages` CHAR(255) "
533 "PRIMARY KEY `Signature`)" );
541 "CREATE TABLE `LaunchCondition` ("
542 "`Condition` CHAR(255) NOT NULL, "
543 "`Description` CHAR(255) NOT NULL "
544 "PRIMARY KEY `Condition`)" );
552 "CREATE TABLE `Property` ("
553 "`Property` CHAR(72) NOT NULL, "
555 "PRIMARY KEY `Property`)" );
563 "CREATE TABLE `InstallExecuteSequence` ("
564 "`Action` CHAR(72) NOT NULL, "
565 "`Condition` CHAR(255), "
567 "PRIMARY KEY `Action`)" );
568 ok(
r ==
ERROR_SUCCESS,
"Failed to create InstallExecuteSequence table: %u\n",
r);
575 "CREATE TABLE `InstallUISequence` ("
576 "`Action` CHAR(72) NOT NULL, "
577 "`Condition` CHAR(255), "
579 "PRIMARY KEY `Action`)" );
587 "CREATE TABLE `Media` ("
588 "`DiskId` SHORT NOT NULL, "
589 "`LastSequence` SHORT NOT NULL, "
590 "`DiskPrompt` CHAR(64), "
591 "`Cabinet` CHAR(255), "
592 "`VolumeLabel` CHAR(32), "
594 "PRIMARY KEY `DiskId`)" );
602 "CREATE TABLE `CCPSearch` ("
603 "`Signature_` CHAR(72) NOT NULL "
604 "PRIMARY KEY `Signature_`)" );
612 "CREATE TABLE `DrLocator` ("
613 "`Signature_` CHAR(72) NOT NULL, "
614 "`Parent` CHAR(72), "
617 "PRIMARY KEY `Signature_`, `Parent`, `Path`)" );
625 "CREATE TABLE `CompLocator` ("
626 "`Signature_` CHAR(72) NOT NULL, "
627 "`ComponentId` CHAR(38) NOT NULL, "
629 "PRIMARY KEY `Signature_`)" );
637 "CREATE TABLE `IniLocator` ("
638 "`Signature_` CHAR(72) NOT NULL, "
639 "`FileName` CHAR(255) NOT NULL, "
640 "`Section` CHAR(96)NOT NULL, "
641 "`Key` CHAR(128)NOT NULL, "
644 "PRIMARY KEY `Signature_`)" );
652 "CREATE TABLE `CustomAction` ("
653 "`Action` CHAR(72) NOT NULL, "
654 "`Type` SHORT NOT NULL, "
655 "`Source` CHAR(75), "
656 "`Target` CHAR(255) "
657 "PRIMARY KEY `Action`)" );
665 "CREATE TABLE `Dialog` ("
666 "`Dialog` CHAR(72) NOT NULL, "
667 "`HCentering` SHORT NOT NULL, "
668 "`VCentering` SHORT NOT NULL, "
669 "`Width` SHORT NOT NULL, "
670 "`Height` SHORT NOT NULL, "
671 "`Attributes` LONG, "
672 "`Title` CHAR(128) LOCALIZABLE, "
673 "`Control_First` CHAR(50) NOT NULL, "
674 "`Control_Default` CHAR(50), "
675 "`Control_Cancel` CHAR(50) "
676 "PRIMARY KEY `Dialog`)");
684 "CREATE TABLE `Control` ("
685 "`Dialog_` CHAR(72) NOT NULL, "
686 "`Control` CHAR(50) NOT NULL, "
687 "`Type` CHAR(20) NOT NULL, "
688 "`X` SHORT NOT NULL, "
689 "`Y` SHORT NOT NULL, "
690 "`Width` SHORT NOT NULL, "
691 "`Height` SHORT NOT NULL, "
692 "`Attributes` LONG, "
693 "`Property` CHAR(50), "
694 "`Text` CHAR(0) LOCALIZABLE, "
695 "`Control_Next` CHAR(50), "
696 "`Help` CHAR(255) LOCALIZABLE "
697 "PRIMARY KEY `Dialog_`, `Control`)");
705 "CREATE TABLE `ControlEvent` ("
706 "`Dialog_` CHAR(72) NOT NULL, "
707 "`Control_` CHAR(50) NOT NULL, "
708 "`Event` CHAR(50) NOT NULL, "
709 "`Argument` CHAR(255) NOT NULL, "
710 "`Condition` CHAR(255), "
712 "PRIMARY KEY `Dialog_`, `Control_`, `Event`, `Argument`, `Condition`)");
720 "CREATE TABLE `ActionText` ("
721 "`Action` CHAR(72) NOT NULL, "
722 "`Description` CHAR(64) LOCALIZABLE, "
723 "`Template` CHAR(128) LOCALIZABLE "
724 "PRIMARY KEY `Action`)");
732 "CREATE TABLE `Upgrade` ("
733 "`UpgradeCode` CHAR(38) NOT NULL, "
734 "`VersionMin` CHAR(20), "
735 "`VersionMax` CHAR(20), "
736 "`Language` CHAR(255), "
737 "`Attributes` SHORT, "
738 "`Remove` CHAR(255), "
739 "`ActionProperty` CHAR(72) NOT NULL "
740 "PRIMARY KEY `UpgradeCode`, `VersionMin`, `VersionMax`, `Language`)" );
759#define add_component_entry(hdb, values) add_entry(__FILE__, __LINE__, "Component", hdb, values, \
760 "INSERT INTO `Component` " \
761 "(`Component`, `ComponentId`, `Directory_`, " \
762 "`Attributes`, `Condition`, `KeyPath`) VALUES( %s )")
764#define add_directory_entry(hdb, values) add_entry(__FILE__, __LINE__, "Directory", hdb, values, \
765 "INSERT INTO `Directory` " \
766 "(`Directory`,`Directory_Parent`,`DefaultDir`) VALUES( %s )")
768#define add_feature_entry(hdb, values) add_entry(__FILE__, __LINE__, "Feature", hdb, values, \
769 "INSERT INTO `Feature` " \
770 "(`Feature`, `Feature_Parent`, `Title`, `Description`, " \
771 "`Display`, `Level`, `Directory_`, `Attributes`) VALUES( %s )")
773#define add_feature_components_entry(hdb, values) add_entry(__FILE__, __LINE__, "FeatureComponents", hdb, values, \
774 "INSERT INTO `FeatureComponents` " \
775 "(`Feature_`, `Component_`) VALUES( %s )")
777#define add_file_entry(hdb, values) add_entry(__FILE__, __LINE__, "File", hdb, values, \
778 "INSERT INTO `File` " \
779 "(`File`, `Component_`, `FileName`, `FileSize`, " \
780 "`Version`, `Language`, `Attributes`, `Sequence`) VALUES( %s )")
782#define add_appsearch_entry(hdb, values) add_entry(__FILE__, __LINE__, "AppSearch", hdb, values, \
783 "INSERT INTO `AppSearch` " \
784 "(`Property`, `Signature_`) VALUES( %s )")
786#define add_signature_entry(hdb, values) add_entry(__FILE__, __LINE__, "Signature", hdb, values, \
787 "INSERT INTO `Signature` " \
788 "(`Signature`, `FileName`, `MinVersion`, `MaxVersion`," \
789 " `MinSize`, `MaxSize`, `MinDate`, `MaxDate`, `Languages`) " \
792#define add_launchcondition_entry(hdb, values) add_entry(__FILE__, __LINE__, "LaunchCondition", hdb, values, \
793 "INSERT INTO `LaunchCondition` " \
794 "(`Condition`, `Description`) VALUES( %s )")
796#define add_property_entry(hdb, values) add_entry(__FILE__, __LINE__, "Property", hdb, values, \
797 "INSERT INTO `Property` (`Property`, `Value`) VALUES( %s )")
799#define update_ProductVersion_property(hdb, value) add_entry(__FILE__, __LINE__, "Property", hdb, value, \
800 "UPDATE `Property` SET `Value` = '%s' WHERE `Property` = 'ProductVersion'")
802#define update_ProductCode_property(hdb, value) add_entry(__FILE__, __LINE__, "Property", hdb, value, \
803 "UPDATE `Property` SET `Value` = '%s' WHERE `Property` = 'ProductCode'")
805#define add_install_execute_sequence_entry(hdb, values) add_entry(__FILE__, __LINE__, "InstallExecuteSequence", hdb, values, \
806 "INSERT INTO `InstallExecuteSequence` " \
807 "(`Action`, `Condition`, `Sequence`) VALUES( %s )")
809#define add_install_ui_sequence_entry(hdb, values) add_entry(__FILE__, __LINE__, "InstallUISequence", hdb, values, \
810 "INSERT INTO `InstallUISequence` " \
811 "(`Action`, `Condition`, `Sequence`) VALUES( %s )")
813#define add_media_entry(hdb, values) add_entry(__FILE__, __LINE__, "Media", hdb, values, \
814 "INSERT INTO `Media` " \
815 "(`DiskId`, `LastSequence`, `DiskPrompt`, " \
816 "`Cabinet`, `VolumeLabel`, `Source`) VALUES( %s )")
818#define add_ccpsearch_entry(hdb, values) add_entry(__FILE__, __LINE__, "CCPSearch", hdb, values, \
819 "INSERT INTO `CCPSearch` (`Signature_`) VALUES( %s )")
821#define add_drlocator_entry(hdb, values) add_entry(__FILE__, __LINE__, "DrLocator", hdb, values, \
822 "INSERT INTO `DrLocator` " \
823 "(`Signature_`, `Parent`, `Path`, `Depth`) VALUES( %s )")
825#define add_complocator_entry(hdb, values) add_entry(__FILE__, __LINE__, "CompLocator", hdb, values, \
826 "INSERT INTO `CompLocator` " \
827 "(`Signature_`, `ComponentId`, `Type`) VALUES( %s )")
829#define add_inilocator_entry(hdb, values) add_entry(__FILE__, __LINE__, "IniLocator", hdb, values, \
830 "INSERT INTO `IniLocator` " \
831 "(`Signature_`, `FileName`, `Section`, `Key`, `Field`, `Type`) " \
834#define add_custom_action_entry(hdb, values) add_entry(__FILE__, __LINE__, "CustomAction", hdb, values, \
835 "INSERT INTO `CustomAction` " \
836 "(`Action`, `Type`, `Source`, `Target`) VALUES( %s )")
838#define add_dialog_entry(hdb, values) add_entry(__FILE__, __LINE__, "Dialog", hdb, values, \
839 "INSERT INTO `Dialog` " \
840 "(`Dialog`, `HCentering`, `VCentering`, `Width`, `Height`, `Attributes`, `Control_First`) VALUES ( %s )")
842#define add_control_entry(hdb, values) add_entry(__FILE__, __LINE__, "Control", hdb, values, \
843 "INSERT INTO `Control` " \
844 "(`Dialog_`, `Control`, `Type`, `X`, `Y`, `Width`, `Height`, `Attributes`, `Text`) VALUES( %s )");
846#define add_controlevent_entry(hdb, values) add_entry(__FILE__, __LINE__, "ControlEvent", hdb, values, \
847 "INSERT INTO `ControlEvent` " \
848 "(`Dialog_`, `Control_`, `Event`, `Argument`, `Condition`, `Ordering`) VALUES( %s )");
850#define add_actiontext_entry(hdb, values) add_entry(__FILE__, __LINE__, "ActionText", hdb, values, \
851 "INSERT INTO `ActionText` " \
852 "(`Action`, `Description`, `Template`) VALUES( %s )");
854#define add_upgrade_entry(hdb, values) add_entry(__FILE__, __LINE__, "Upgrade", hdb, values, \
855 "INSERT INTO `Upgrade` " \
856 "(`UpgradeCode`, `VersionMin`, `VersionMax`, `Language`, `Attributes`, `Remove`, `ActionProperty`) VALUES( %s )");
862 "INSERT INTO `RegLocator` (`Signature_`, `Root`, `Key`, `Name`, `Type`) "
863 "VALUES( '%s', %u, '%s', '%s', %u )";
886 "Installation Database");
890 "Installation Database");
902 "{913B8D18-FBB6-4CAC-A239-C74C11E3FA74}");
941 "CREATE TABLE `Directory` ( "
942 "`Directory` CHAR(255) NOT NULL, "
943 "`Directory_Parent` CHAR(255), "
944 "`DefaultDir` CHAR(255) NOT NULL "
945 "PRIMARY KEY `Directory`)" );
957 sprintf(szPackage,
"#%lu", hdb);
1009#define roundoffs(a, b, r) (((BYTE *)(b) - (BYTE *)(a) + ((r) - 1)) & ~((r) - 1))
1010#define roundpos(a, b, r) (((BYTE *)(a)) + roundoffs(a, b, r))
1069 return pSRSetRestorePointA(&spec,
status);
1076 res = pSRRemoveRestorePoint(seq_number);
1078 trace(
"Failed to remove the restore point: %#lx\n",
res);
1094 skip(
"Not enough rights to perform tests\n");
1116 skip(
"Not enough rights to perform tests\n");
1138 WCHAR bufferW[0x80];
1146 skip(
"Not enough rights to perform tests\n");
1207 ok(rec,
"MsiCreate record failed\n");
1228 ok ( hdb,
"failed to create package database\n" );
1233 add_component_entry( hdb,
"'RootComp', '{83e2694d-0864-4124-9323-6d37630912a1}', 'TARGETDIR', 8, '', 'RootFile'" );
1234 add_component_entry( hdb,
"'TestComp', '{A3FB59C8-C293-4F7E-B8C5-F0E1D8EEE4E5}', 'TestDir', 0, '', 'TestFile'" );
1247 add_file_entry( hdb,
"'RootFile', 'RootComp', 'rootfile.txt', 0, '', '1033', 8192, 1" );
1248 add_file_entry( hdb,
"'TestFile', 'TestComp', 'testfile.txt', 0, '', '1033', 8192, 1" );
1253 skip(
"Not enough rights to perform tests\n");
1288 sz =
sizeof tempdir - 1;
1301 "MsiSetTargetPath on file returned %d\n",
r );
1305 "MsiSetTargetPath on 'subdir' of file returned %d\n",
r );
1333 lstrcatA( tempdir,
"TestParent\\" );
1344 "Expected \"C:\\one\\two\\TestDir\\\", got \"%s\"\n",
buffer );
1349 "Expected C:\\one\\two\\TestDir\\testfile.txt, got %s\n",
buffer );
1395 skip(
"Not enough rights to perform tests\n");
2122 "wrong return val (%d)\n",
r);
2126 "wrong return val (%d)\n",
r);
2130 "wrong return val (%d)\n",
r);
2134 "wrong return val (%d)\n",
r);
2145 ok(!
r,
"'%s': got %u\n", prop,
r);
2169 skip(
"Not enough rights to perform tests\n");
2183 ok(!
r,
"got %u\n",
r);
2191 ok(!
r,
"got %u\n",
r);
2192 ok(sz == 0,
"got size %lu\n", sz);
2199 ok(sz == 0,
"got size %lu\n", sz);
2204 ok(!
r,
"got %u\n",
r);
2206 ok(sz == 0,
"got size %lu\n", sz);
2216 ok(!
r,
"got %u\n",
r);
2222 ok(!
r,
"got %u\n",
r);
2226 ok(!
r,
"got %u\n",
r);
2230 ok(!
r,
"got %u\n",
r);
2235 ok(!
r,
"got %u\n",
r);
2239 ok(!
r,
"got %u\n",
r);
2244 ok(!
r,
"got %u\n",
r);
2248 ok(!
r,
"got %u\n",
r);
2255 ok(!
r,
"got %u\n",
r);
2256 ok(sz == 3,
"got size %lu\n", sz);
2263 ok(sz == 3,
"got size %lu\n", sz);
2270 ok(sz == 3,
"got size %lu\n", sz);
2277 ok(sz == 3,
"got size %lu\n", sz);
2282 ok(!
r,
"got %u\n",
r);
2284 ok(sz == 3,
"got size %lu\n", sz);
2288 ok(!
r,
"got %u\n",
r);
2289 ok(sz == 3,
"got size %lu\n", sz);
2296 ok(sz == 3,
"got size %lu\n", sz);
2303 ok(sz == 3,
"got size %lu\n", sz);
2310 ok(sz == 3,
"got size %lu\n", sz);
2315 ok(!
r,
"got %u\n",
r);
2317 ok(sz == 3,
"got size %lu\n", sz);
2323 check_prop(hpkg,
"MetadataCompName",
"Photoshop.dll", 1);
2357 ok(sz ==
len,
"wrong size %lu\n", sz);
2379 ok( hdb,
"failed to create package\n");
2384 skip(
"Not enough rights to perform tests\n");
2394 query =
"CREATE TABLE `_Property` ( "
2395 "`foo` INT NOT NULL, `bar` INT LOCALIZABLE PRIMARY KEY `foo`)";
2404 ok( hdb,
"failed to create package\n");
2406 query =
"CREATE TABLE `_Property` ( "
2407 "`foo` INT NOT NULL, `bar` INT LOCALIZABLE PRIMARY KEY `foo`)";
2411 query =
"ALTER `_Property` ADD `foo` INTEGER";
2415 query =
"ALTER TABLE `_Property` ADD `foo` INTEGER";
2419 query =
"ALTER TABLE `_Property` ADD `extra` INTEGER";
2423 sprintf(package,
"#%lu", hdb);
2433 ok (hdb,
"failed to create package database\n");
2454 ok(found,
"prop should be in the _Property table\n");
2458 query =
"SELECT * FROM `_Property` WHERE `Property` = 'dantes'";
2463 ok(found ==
FALSE,
"dantes should not be in the _Property table\n");
2475 ok(found ==
TRUE,
"dantes should be in the _Property table\n");
2485 ok( sz ==
sizeof(
"\0np") - 1,
"got %lu\n", sz );
2488 ok(found ==
TRUE,
"prop2 should be in the _Property table\n");
2577 skip(
"Not enough rights to perform tests\n");
2608 "Expected ERROR_INSTALL_PACKAGE_INVALID, got %d\n",
r);
2610 query =
"CREATE TABLE `Property` ( "
2611 "`Property` CHAR(72), `Value` CHAR(0) "
2612 "PRIMARY KEY `Property`)";
2616 query =
"CREATE TABLE `InstallExecuteSequence` ("
2617 "`Action` CHAR(72), `Condition` CHAR(0), `Sequence` INTEGER "
2618 "PRIMARY KEY `Action`)";
2626 "Expected ERROR_INSTALL_PACKAGE_INVALID, got %d\n",
r);
2645 "Expected ERROR_INSTALL_PACKAGE_INVALID, got %d\n",
r);
2650 "Expected ERROR_SUCCESS, got %d\n",
r);
2667 skip(
"Not enough rights to perform tests\n");
2677 ok(hrec,
"create record failed\n");
2693 ok( sz == 3,
"size wrong\n");
2701 ok( sz == 3,
"size wrong\n");
2711 ok( sz == 3,
"size wrong\n");
2719 ok( sz == 1,
"size wrong\n");
2728 ok( sz == 3,
"size wrong\n");
2738 ok( sz == 3,
"size wrong\n");
2760 ok ( hdb,
"failed to create package database\n");
2764 "'I am a really long directory'" );
2780 add_file_entry( hdb,
"'frontal_file', 'frontal', 'frontal.txt', 0, '', '1033', 8192, 1" );
2781 add_file_entry( hdb,
"'parietal_file', 'parietal', 'parietal.txt', 0, '', '1033', 8192, 1" );
2782 add_file_entry( hdb,
"'temporal_file', 'temporal', 'temporal.txt', 0, '', '1033', 8192, 1" );
2794 skip(
"Not enough rights to perform tests\n");
2821 ok( !
lstrcmpA(
buf,
"1: ringer " ),
"Expected '1: ringer ', got %s\n",
buf );
2827 ok( !
lstrcmpA(
buf,
"1: ringer " ),
"Expected '1: ringer ', got %s\n",
buf );
2842 ok( !
lstrcmpA(
buf,
"1: crazyval " ),
"Expected '1: crazyval ', got %s\n",
buf );
2933 ok( !
lstrcmpA(
buf,
"[Bracket Text]" ),
"Expected '[Bracket Text]', got %s\n",
buf);
2961 ok( !
memcmp(
buf,
"\0np",
sizeof(
"\0np") ),
"wrong value\n");
2962 ok(
size ==
sizeof(
"\0np") - 1,
"got %lu\n",
size );
2996 sprintf(
buf,
"%sI am a really long directory\\temporal.txt",
root );
3018 ok(
state == expected_state,
"%u: expected state %d got %d\n",
3021 ok(
action == expected_action,
"%u: expected action %d got %d\n",
3026 ok(
state == 0xdeadbee,
"%u: expected state 0xdeadbee got %d\n",
line,
state );
3044 ok(
state == expected_state,
"%u: expected state %d got %d\n",
3047 ok(
action == expected_action,
"%u: expected action %d got %d\n",
3052 ok(
state == 0xdeadbee,
"%u: expected state 0xdeadbee got %d\n",
3055 ok(
action == 0xdeadbee,
"%u: expected action 0xdeadbee got %d\n",
3062 static const char msifile2[] =
"winetest2-package.msi";
3063 static const char msifile3[] =
"winetest3-package.msi";
3064 static const char msifile4[] =
"winetest4-package.msi";
3066 static const WCHAR msifile3W[] =
L"winetest3-package.msi";
3067 static const WCHAR msifile4W[] =
L"winetest4-package.msi";
3069 DWORD cache_file_name_len;
3080 skip(
"process is limited\n");
3085 ok ( hdb,
"failed to create package database\n" );
3090 add_property_entry( hdb,
"'ProductCode', '{7262AC98-EEBD-4364-8CE3-D654F6A425B9}'" );
3095 add_property_entry( hdb,
"'UpgradeCode', '{3494EEEA-4221-4A66-802E-DED8916BC5C5}'" );
3121 add_component_entry( hdb,
"'alpha', '{467EC132-739D-4784-A37B-677AA43DBC94}', 'TARGETDIR', 0, '', 'alpha_file'" );
3124 add_component_entry( hdb,
"'beta', '{2C1F189C-24A6-4C34-B26B-994A6C026506}', 'TARGETDIR', 1, '', 'beta_file'" );
3127 add_component_entry( hdb,
"'gamma', '{C271E2A4-DE2E-4F70-86D1-6984AF7DE2CA}', 'TARGETDIR', 2, '', 'gamma_file'" );
3130 add_component_entry( hdb,
"'theta', '{4EB3129D-81A8-48D5-9801-75600FED3DD9}', 'TARGETDIR', 8, '', 'theta_file'" );
3136 add_component_entry( hdb,
"'delta', '{938FD4F2-C648-4259-A03C-7AA3B45643F3}', 'TARGETDIR', 0, '', 'delta_file'" );
3139 add_component_entry( hdb,
"'epsilon', '{D59713B6-C11D-47F2-A395-1E5321781190}', 'TARGETDIR', 1, '', 'epsilon_file'" );
3142 add_component_entry( hdb,
"'zeta', '{377D33AB-2FAA-42B9-A629-0C0DAE9B9C7A}', 'TARGETDIR', 2, '', 'zeta_file'" );
3145 add_component_entry( hdb,
"'iota', '{5D36F871-B5ED-4801-9E0F-C46B9E5C9669}', 'TARGETDIR', 8, '', 'iota_file'" );
3157 add_component_entry( hdb,
"'eta', '{DD89003F-0DD4-41B8-81C0-3411A7DA2695}', 'TARGETDIR', 1, '', 'eta_file'" );
3160 add_component_entry( hdb,
"'kappa', '{D6B93DC3-8DA5-4769-9888-42BFE156BB8B}', 'TARGETDIR', 1, '', 'kappa_file'" );
3166 add_component_entry( hdb,
"'lambda', '{6528C5E4-02A4-4636-A214-7A66A6C35B64}', 'TARGETDIR', 0, '', 'lambda_file'" );
3169 add_component_entry( hdb,
"'mu', '{97014BAB-6C56-4013-9A63-2BF913B42519}', 'TARGETDIR', 1, '', 'mu_file'" );
3172 add_component_entry( hdb,
"'nu', '{943DD0D8-5808-4954-8526-3B8493FEDDCD}', 'TARGETDIR', 2, '', 'nu_file'" );
3175 add_component_entry( hdb,
"'xi', '{D6CF9EF7-6FCF-4930-B34B-F938AEFF9BDB}', 'TARGETDIR', 8, '', 'xi_file'" );
3181 add_component_entry( hdb,
"'omicron', '{7B57521D-15DB-4141-9AA6-01D934A4433F}', 'TARGETDIR', 0, '', 'omicron_file'" );
3184 add_component_entry( hdb,
"'pi', '{FB85346B-378E-4492-8769-792305471C81}', 'TARGETDIR', 1, '', 'pi_file'" );
3187 add_component_entry( hdb,
"'rho', '{798F2047-7B0C-4783-8BB0-D703E554114B}', 'TARGETDIR', 2, '', 'rho_file'" );
3190 add_component_entry( hdb,
"'sigma', '{5CE9DDA8-B67B-4736-9D93-99D61C5B93E7}', 'TARGETDIR', 8, '', 'sigma_file'" );
3195 add_component_entry( hdb,
"'tau', '{07DEB510-677C-4A6F-A0A6-7CD8EFEA77ED}', 'TARGETDIR', 1, '', 'tau_file'" );
3200 add_component_entry( hdb,
"'phi', '{9F0594C5-35AD-43EA-94DD-8DF73FAA664D}', 'TARGETDIR', 1, '', 'phi_file'" );
3205 add_component_entry( hdb,
"'chi', '{E6B539AB-5DA9-4236-A2D2-E341A50B4C38}', 'TARGETDIR', 1, '', 'chi_file'" );
3210 add_component_entry( hdb,
"'psi', '{A06B23B5-746B-427A-8A6E-FD6AC8F46A95}', 'TARGETDIR', 1, '', 'psi_file'" );
3215 add_component_entry( hdb,
"'upsilon', '{557e0c04-ceba-4c58-86a9-4a73352e8cf6}', 'TARGETDIR', 1, '', 'upsilon_file'" );
3248 add_file_entry( hdb,
"'alpha_file', 'alpha', 'alpha.txt', 100, '', '1033', 8192, 1" );
3249 add_file_entry( hdb,
"'beta_file', 'beta', 'beta.txt', 0, '', '1033', 8192, 1" );
3250 add_file_entry( hdb,
"'gamma_file', 'gamma', 'gamma.txt', 0, '', '1033', 8192, 1" );
3251 add_file_entry( hdb,
"'theta_file', 'theta', 'theta.txt', 0, '', '1033', 8192, 1" );
3252 add_file_entry( hdb,
"'delta_file', 'delta', 'delta.txt', 0, '', '1033', 8192, 1" );
3253 add_file_entry( hdb,
"'epsilon_file', 'epsilon', 'epsilon.txt', 0, '', '1033', 8192, 1" );
3254 add_file_entry( hdb,
"'zeta_file', 'zeta', 'zeta.txt', 0, '', '1033', 8192, 1" );
3255 add_file_entry( hdb,
"'iota_file', 'iota', 'iota.txt', 0, '', '1033', 8192, 1" );
3258 add_file_entry( hdb,
"'eta_file', 'eta', 'eta.txt', 0, '', '1033', 16384, 1" );
3260 add_file_entry( hdb,
"'kappa_file', 'kappa', 'kappa.txt', 0, '', '1033', 8192, 1" );
3261 add_file_entry( hdb,
"'lambda_file', 'lambda', 'lambda.txt', 100, '', '1033', 8192, 1" );
3262 add_file_entry( hdb,
"'mu_file', 'mu', 'mu.txt', 100, '', '1033', 8192, 1" );
3263 add_file_entry( hdb,
"'nu_file', 'nu', 'nu.txt', 100, '', '1033', 8192, 1" );
3264 add_file_entry( hdb,
"'xi_file', 'xi', 'xi.txt', 100, '', '1033', 8192, 1" );
3265 add_file_entry( hdb,
"'omicron_file', 'omicron', 'omicron.txt', 100, '', '1033', 8192, 1" );
3266 add_file_entry( hdb,
"'pi_file', 'pi', 'pi.txt', 100, '', '1033', 8192, 1" );
3267 add_file_entry( hdb,
"'rho_file', 'rho', 'rho.txt', 100, '', '1033', 8192, 1" );
3268 add_file_entry( hdb,
"'sigma_file', 'sigma', 'sigma.txt', 100, '', '1033', 8192, 1" );
3269 add_file_entry( hdb,
"'tau_file', 'tau', 'tau.txt', 100, '', '1033', 8192, 1" );
3270 add_file_entry( hdb,
"'phi_file', 'phi', 'phi.txt', 100, '', '1033', 8192, 1" );
3271 add_file_entry( hdb,
"'chi_file', 'chi', 'chi.txt', 100, '', '1033', 8192, 1" );
3272 add_file_entry( hdb,
"'psi_file', 'psi', 'psi.txt', 100, '', '1033', 8192, 1" );
3273 add_file_entry( hdb,
"'upsilon_file', 'upsilon', 'upsilon.txt', 0, '', '1033', 16384, 1" );
3288 skip(
"Not enough rights to perform tests\n");