diff options
| author | Sean Hall <r.sean.hall@gmail.com> | 2021-12-12 21:52:29 -0600 |
|---|---|---|
| committer | Sean Hall <r.sean.hall@gmail.com> | 2021-12-13 14:44:02 -0600 |
| commit | 72b024f33d9630432e8aad2bf8261051a0df1e41 (patch) | |
| tree | 3ff13dffd1a3f93b87f789716bf4c47268a845d9 /src/burn/test/BurnUnitTest/PlanTest.cpp | |
| parent | e223ab393bdf04a9c3d0d2144b48a10d7b2650a2 (diff) | |
| download | wix-72b024f33d9630432e8aad2bf8261051a0df1e41.tar.gz wix-72b024f33d9630432e8aad2bf8261051a0df1e41.tar.bz2 wix-72b024f33d9630432e8aad2bf8261051a0df1e41.zip | |
After rolling back in a non-vital rollback boundary, skip to its end.
Fixes #6309
Diffstat (limited to 'src/burn/test/BurnUnitTest/PlanTest.cpp')
| -rw-r--r-- | src/burn/test/BurnUnitTest/PlanTest.cpp | 88 |
1 files changed, 62 insertions, 26 deletions
diff --git a/src/burn/test/BurnUnitTest/PlanTest.cpp b/src/burn/test/BurnUnitTest/PlanTest.cpp index 921f2a50..627da49a 100644 --- a/src/burn/test/BurnUnitTest/PlanTest.cpp +++ b/src/burn/test/BurnUnitTest/PlanTest.cpp | |||
| @@ -81,7 +81,7 @@ namespace Bootstrapper | |||
| 81 | fRollback = FALSE; | 81 | fRollback = FALSE; |
| 82 | dwIndex = 0; | 82 | dwIndex = 0; |
| 83 | DWORD dwExecuteCheckpointId = 2; | 83 | DWORD dwExecuteCheckpointId = 2; |
| 84 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | 84 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); |
| 85 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 85 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 86 | ValidateExecuteWaitCachePackage(pPlan, fRollback, dwIndex++, L"PackageA"); | 86 | ValidateExecuteWaitCachePackage(pPlan, fRollback, dwIndex++, L"PackageA"); |
| 87 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 87 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| @@ -92,7 +92,8 @@ namespace Bootstrapper | |||
| 92 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PackageA", L"{E6469F05-BDC8-4EB8-B218-67412543EFAA}", BURN_DEPENDENCY_ACTION_REGISTER); | 92 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PackageA", L"{E6469F05-BDC8-4EB8-B218-67412543EFAA}", BURN_DEPENDENCY_ACTION_REGISTER); |
| 93 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 93 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 94 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 94 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 95 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"rbaOCA08D8ky7uBOK71_6FWz1K3TuQ", TRUE, TRUE); | 95 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); |
| 96 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"rbaOCA08D8ky7uBOK71_6FWz1K3TuQ", TRUE, TRUE); | ||
| 96 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 97 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 97 | ValidateExecuteBeginMsiTransaction(pPlan, fRollback, dwIndex++, L"rbaOCA08D8ky7uBOK71_6FWz1K3TuQ"); | 98 | ValidateExecuteBeginMsiTransaction(pPlan, fRollback, dwIndex++, L"rbaOCA08D8ky7uBOK71_6FWz1K3TuQ"); |
| 98 | dwExecuteCheckpointId += 1; // cache checkpoints | 99 | dwExecuteCheckpointId += 1; // cache checkpoints |
| @@ -115,13 +116,14 @@ namespace Bootstrapper | |||
| 115 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 116 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 116 | ValidateExecuteCommitMsiTransaction(pPlan, fRollback, dwIndex++, L"rbaOCA08D8ky7uBOK71_6FWz1K3TuQ"); | 117 | ValidateExecuteCommitMsiTransaction(pPlan, fRollback, dwIndex++, L"rbaOCA08D8ky7uBOK71_6FWz1K3TuQ"); |
| 117 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 118 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 119 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); | ||
| 118 | ValidateExecuteExePackage(pPlan, fRollback, dwIndex++, L"{FD9920AD-DBCA-4C6C-8CD5-B47431CE8D21}", BOOTSTRAPPER_ACTION_STATE_UNINSTALL, NULL); | 120 | ValidateExecuteExePackage(pPlan, fRollback, dwIndex++, L"{FD9920AD-DBCA-4C6C-8CD5-B47431CE8D21}", BOOTSTRAPPER_ACTION_STATE_UNINSTALL, NULL); |
| 119 | Assert::Equal(dwIndex, pPlan->cExecuteActions); | 121 | Assert::Equal(dwIndex, pPlan->cExecuteActions); |
| 120 | 122 | ||
| 121 | fRollback = TRUE; | 123 | fRollback = TRUE; |
| 122 | dwIndex = 0; | 124 | dwIndex = 0; |
| 123 | dwExecuteCheckpointId = 2; | 125 | dwExecuteCheckpointId = 2; |
| 124 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | 126 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); |
| 125 | ValidateExecuteUncachePackage(pPlan, fRollback, dwIndex++, L"PackageA"); | 127 | ValidateExecuteUncachePackage(pPlan, fRollback, dwIndex++, L"PackageA"); |
| 126 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 128 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 127 | ValidateExecutePackageProvider(pPlan, fRollback, dwIndex++, L"PackageA", BURN_DEPENDENCY_ACTION_UNREGISTER); | 129 | ValidateExecutePackageProvider(pPlan, fRollback, dwIndex++, L"PackageA", BURN_DEPENDENCY_ACTION_UNREGISTER); |
| @@ -132,7 +134,8 @@ namespace Bootstrapper | |||
| 132 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 134 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 133 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 135 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 134 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 136 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 135 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"rbaOCA08D8ky7uBOK71_6FWz1K3TuQ", TRUE, TRUE); | 137 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); |
| 138 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"rbaOCA08D8ky7uBOK71_6FWz1K3TuQ", TRUE, TRUE); | ||
| 136 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 139 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 137 | ValidateExecuteUncachePackage(pPlan, fRollback, dwIndex++, L"PackageB"); | 140 | ValidateExecuteUncachePackage(pPlan, fRollback, dwIndex++, L"PackageB"); |
| 138 | dwExecuteCheckpointId += 1; // cache checkpoints | 141 | dwExecuteCheckpointId += 1; // cache checkpoints |
| @@ -151,6 +154,7 @@ namespace Bootstrapper | |||
| 151 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 154 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 152 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 155 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 153 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 156 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 157 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); | ||
| 154 | ValidateExecuteExePackage(pPlan, fRollback, dwIndex++, L"{FD9920AD-DBCA-4C6C-8CD5-B47431CE8D21}", BOOTSTRAPPER_ACTION_STATE_INSTALL, NULL); | 158 | ValidateExecuteExePackage(pPlan, fRollback, dwIndex++, L"{FD9920AD-DBCA-4C6C-8CD5-B47431CE8D21}", BOOTSTRAPPER_ACTION_STATE_INSTALL, NULL); |
| 155 | Assert::Equal(dwIndex, pPlan->cRollbackActions); | 159 | Assert::Equal(dwIndex, pPlan->cRollbackActions); |
| 156 | 160 | ||
| @@ -202,7 +206,7 @@ namespace Bootstrapper | |||
| 202 | fRollback = FALSE; | 206 | fRollback = FALSE; |
| 203 | dwIndex = 0; | 207 | dwIndex = 0; |
| 204 | DWORD dwExecuteCheckpointId = 1; | 208 | DWORD dwExecuteCheckpointId = 1; |
| 205 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"rbaOCA08D8ky7uBOK71_6FWz1K3TuQ", TRUE, TRUE); | 209 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"rbaOCA08D8ky7uBOK71_6FWz1K3TuQ", TRUE, TRUE); |
| 206 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 210 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 207 | ValidateExecuteBeginMsiTransaction(pPlan, fRollback, dwIndex++, L"rbaOCA08D8ky7uBOK71_6FWz1K3TuQ"); | 211 | ValidateExecuteBeginMsiTransaction(pPlan, fRollback, dwIndex++, L"rbaOCA08D8ky7uBOK71_6FWz1K3TuQ"); |
| 208 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 212 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| @@ -219,7 +223,8 @@ namespace Bootstrapper | |||
| 219 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 223 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 220 | ValidateExecuteCommitMsiTransaction(pPlan, fRollback, dwIndex++, L"rbaOCA08D8ky7uBOK71_6FWz1K3TuQ"); | 224 | ValidateExecuteCommitMsiTransaction(pPlan, fRollback, dwIndex++, L"rbaOCA08D8ky7uBOK71_6FWz1K3TuQ"); |
| 221 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 225 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 222 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | 226 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); |
| 227 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | ||
| 223 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 228 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 224 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PackageA", L"{E6469F05-BDC8-4EB8-B218-67412543EFAA}", BURN_DEPENDENCY_ACTION_UNREGISTER); | 229 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PackageA", L"{E6469F05-BDC8-4EB8-B218-67412543EFAA}", BURN_DEPENDENCY_ACTION_UNREGISTER); |
| 225 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 230 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| @@ -228,12 +233,13 @@ namespace Bootstrapper | |||
| 228 | ValidateExecuteMsiPackage(pPlan, fRollback, dwIndex++, L"PackageA", BOOTSTRAPPER_ACTION_STATE_UNINSTALL, BURN_MSI_PROPERTY_UNINSTALL, INSTALLUILEVEL_NONE, FALSE, BOOTSTRAPPER_MSI_FILE_VERSIONING_MISSING_OR_OLDER, 0); | 233 | ValidateExecuteMsiPackage(pPlan, fRollback, dwIndex++, L"PackageA", BOOTSTRAPPER_ACTION_STATE_UNINSTALL, BURN_MSI_PROPERTY_UNINSTALL, INSTALLUILEVEL_NONE, FALSE, BOOTSTRAPPER_MSI_FILE_VERSIONING_MISSING_OR_OLDER, 0); |
| 229 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 234 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 230 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 235 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 236 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); | ||
| 231 | Assert::Equal(dwIndex, pPlan->cExecuteActions); | 237 | Assert::Equal(dwIndex, pPlan->cExecuteActions); |
| 232 | 238 | ||
| 233 | fRollback = TRUE; | 239 | fRollback = TRUE; |
| 234 | dwIndex = 0; | 240 | dwIndex = 0; |
| 235 | dwExecuteCheckpointId = 1; | 241 | dwExecuteCheckpointId = 1; |
| 236 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"rbaOCA08D8ky7uBOK71_6FWz1K3TuQ", TRUE, TRUE); | 242 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"rbaOCA08D8ky7uBOK71_6FWz1K3TuQ", TRUE, TRUE); |
| 237 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 243 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 238 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PackageC", L"{E6469F05-BDC8-4EB8-B218-67412543EFAA}", BURN_DEPENDENCY_ACTION_REGISTER); | 244 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PackageC", L"{E6469F05-BDC8-4EB8-B218-67412543EFAA}", BURN_DEPENDENCY_ACTION_REGISTER); |
| 239 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 245 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| @@ -246,7 +252,8 @@ namespace Bootstrapper | |||
| 246 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 252 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 247 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 253 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 248 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 254 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 249 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | 255 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); |
| 256 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | ||
| 250 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PackageA", L"{E6469F05-BDC8-4EB8-B218-67412543EFAA}", BURN_DEPENDENCY_ACTION_REGISTER); | 257 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PackageA", L"{E6469F05-BDC8-4EB8-B218-67412543EFAA}", BURN_DEPENDENCY_ACTION_REGISTER); |
| 251 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 258 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 252 | ValidateExecutePackageProvider(pPlan, fRollback, dwIndex++, L"PackageA", BURN_DEPENDENCY_ACTION_REGISTER); | 259 | ValidateExecutePackageProvider(pPlan, fRollback, dwIndex++, L"PackageA", BURN_DEPENDENCY_ACTION_REGISTER); |
| @@ -255,6 +262,7 @@ namespace Bootstrapper | |||
| 255 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 262 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 256 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 263 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 257 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 264 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 265 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); | ||
| 258 | Assert::Equal(dwIndex, pPlan->cRollbackActions); | 266 | Assert::Equal(dwIndex, pPlan->cRollbackActions); |
| 259 | 267 | ||
| 260 | Assert::Equal(3ul, pPlan->cExecutePackagesTotal); | 268 | Assert::Equal(3ul, pPlan->cExecutePackagesTotal); |
| @@ -319,7 +327,7 @@ namespace Bootstrapper | |||
| 319 | fRollback = FALSE; | 327 | fRollback = FALSE; |
| 320 | dwIndex = 0; | 328 | dwIndex = 0; |
| 321 | DWORD dwExecuteCheckpointId = 2; | 329 | DWORD dwExecuteCheckpointId = 2; |
| 322 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | 330 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); |
| 323 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 331 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 324 | ValidateExecuteWaitCachePackage(pPlan, fRollback, dwIndex++, L"PackageA"); | 332 | ValidateExecuteWaitCachePackage(pPlan, fRollback, dwIndex++, L"PackageA"); |
| 325 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 333 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| @@ -330,12 +338,13 @@ namespace Bootstrapper | |||
| 330 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PackageA", L"{A6F0CBF7-1578-450C-B9D7-9CF2EEC40002}", BURN_DEPENDENCY_ACTION_REGISTER); | 338 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PackageA", L"{A6F0CBF7-1578-450C-B9D7-9CF2EEC40002}", BURN_DEPENDENCY_ACTION_REGISTER); |
| 331 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 339 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 332 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 340 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 341 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); | ||
| 333 | Assert::Equal(dwIndex, pPlan->cExecuteActions); | 342 | Assert::Equal(dwIndex, pPlan->cExecuteActions); |
| 334 | 343 | ||
| 335 | fRollback = TRUE; | 344 | fRollback = TRUE; |
| 336 | dwIndex = 0; | 345 | dwIndex = 0; |
| 337 | dwExecuteCheckpointId = 2; | 346 | dwExecuteCheckpointId = 2; |
| 338 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | 347 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); |
| 339 | ValidateExecuteUncachePackage(pPlan, fRollback, dwIndex++, L"PackageA"); | 348 | ValidateExecuteUncachePackage(pPlan, fRollback, dwIndex++, L"PackageA"); |
| 340 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 349 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 341 | ValidateExecutePackageProvider(pPlan, fRollback, dwIndex++, L"PackageA", BURN_DEPENDENCY_ACTION_UNREGISTER); | 350 | ValidateExecutePackageProvider(pPlan, fRollback, dwIndex++, L"PackageA", BURN_DEPENDENCY_ACTION_UNREGISTER); |
| @@ -346,6 +355,7 @@ namespace Bootstrapper | |||
| 346 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 355 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 347 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 356 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 348 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 357 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 358 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); | ||
| 349 | Assert::Equal(dwIndex, pPlan->cRollbackActions); | 359 | Assert::Equal(dwIndex, pPlan->cRollbackActions); |
| 350 | 360 | ||
| 351 | Assert::Equal(1ul, pPlan->cExecutePackagesTotal); | 361 | Assert::Equal(1ul, pPlan->cExecutePackagesTotal); |
| @@ -401,22 +411,24 @@ namespace Bootstrapper | |||
| 401 | fRollback = FALSE; | 411 | fRollback = FALSE; |
| 402 | dwIndex = 0; | 412 | dwIndex = 0; |
| 403 | DWORD dwExecuteCheckpointId = 2; | 413 | DWORD dwExecuteCheckpointId = 2; |
| 404 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | 414 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); |
| 405 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 415 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 406 | ValidateExecuteWaitCachePackage(pPlan, fRollback, dwIndex++, L"PackageA"); | 416 | ValidateExecuteWaitCachePackage(pPlan, fRollback, dwIndex++, L"PackageA"); |
| 407 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 417 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 408 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 418 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 419 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); | ||
| 409 | Assert::Equal(dwIndex, pPlan->cExecuteActions); | 420 | Assert::Equal(dwIndex, pPlan->cExecuteActions); |
| 410 | 421 | ||
| 411 | fRollback = TRUE; | 422 | fRollback = TRUE; |
| 412 | dwIndex = 0; | 423 | dwIndex = 0; |
| 413 | dwExecuteCheckpointId = 2; | 424 | dwExecuteCheckpointId = 2; |
| 414 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | 425 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); |
| 415 | ValidateExecuteUncachePackage(pPlan, fRollback, dwIndex++, L"PackageA"); | 426 | ValidateExecuteUncachePackage(pPlan, fRollback, dwIndex++, L"PackageA"); |
| 416 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 427 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 417 | ValidateExecutePackageProvider(pPlan, fRollback, dwIndex++, L"PackageA", BURN_DEPENDENCY_ACTION_UNREGISTER); | 428 | ValidateExecutePackageProvider(pPlan, fRollback, dwIndex++, L"PackageA", BURN_DEPENDENCY_ACTION_UNREGISTER); |
| 418 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 429 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 419 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 430 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 431 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); | ||
| 420 | Assert::Equal(dwIndex, pPlan->cRollbackActions); | 432 | Assert::Equal(dwIndex, pPlan->cRollbackActions); |
| 421 | 433 | ||
| 422 | Assert::Equal(0ul, pPlan->cExecutePackagesTotal); | 434 | Assert::Equal(0ul, pPlan->cExecutePackagesTotal); |
| @@ -472,7 +484,7 @@ namespace Bootstrapper | |||
| 472 | fRollback = FALSE; | 484 | fRollback = FALSE; |
| 473 | dwIndex = 0; | 485 | dwIndex = 0; |
| 474 | DWORD dwExecuteCheckpointId = 2; | 486 | DWORD dwExecuteCheckpointId = 2; |
| 475 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | 487 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); |
| 476 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 488 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 477 | ValidateExecuteWaitCachePackage(pPlan, fRollback, dwIndex++, L"PackageA"); | 489 | ValidateExecuteWaitCachePackage(pPlan, fRollback, dwIndex++, L"PackageA"); |
| 478 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 490 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| @@ -483,13 +495,14 @@ namespace Bootstrapper | |||
| 483 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PackageA", L"{A6F0CBF7-1578-450C-B9D7-9CF2EEC40002}", BURN_DEPENDENCY_ACTION_REGISTER); | 495 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PackageA", L"{A6F0CBF7-1578-450C-B9D7-9CF2EEC40002}", BURN_DEPENDENCY_ACTION_REGISTER); |
| 484 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 496 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 485 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 497 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 498 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); | ||
| 486 | ValidateExecuteExePackage(pPlan, fRollback, dwIndex++, L"{FD9920AD-DBCA-4C6C-8CD5-B47431CE8D21}", BOOTSTRAPPER_ACTION_STATE_UNINSTALL, NULL); | 499 | ValidateExecuteExePackage(pPlan, fRollback, dwIndex++, L"{FD9920AD-DBCA-4C6C-8CD5-B47431CE8D21}", BOOTSTRAPPER_ACTION_STATE_UNINSTALL, NULL); |
| 487 | Assert::Equal(dwIndex, pPlan->cExecuteActions); | 500 | Assert::Equal(dwIndex, pPlan->cExecuteActions); |
| 488 | 501 | ||
| 489 | fRollback = TRUE; | 502 | fRollback = TRUE; |
| 490 | dwIndex = 0; | 503 | dwIndex = 0; |
| 491 | dwExecuteCheckpointId = 2; | 504 | dwExecuteCheckpointId = 2; |
| 492 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | 505 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); |
| 493 | ValidateExecuteUncachePackage(pPlan, fRollback, dwIndex++, L"PackageA"); | 506 | ValidateExecuteUncachePackage(pPlan, fRollback, dwIndex++, L"PackageA"); |
| 494 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 507 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 495 | ValidateExecutePackageProvider(pPlan, fRollback, dwIndex++, L"PackageA", BURN_DEPENDENCY_ACTION_UNREGISTER); | 508 | ValidateExecutePackageProvider(pPlan, fRollback, dwIndex++, L"PackageA", BURN_DEPENDENCY_ACTION_UNREGISTER); |
| @@ -500,6 +513,7 @@ namespace Bootstrapper | |||
| 500 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 513 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 501 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 514 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 502 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 515 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 516 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); | ||
| 503 | ValidateExecuteExePackage(pPlan, fRollback, dwIndex++, L"{FD9920AD-DBCA-4C6C-8CD5-B47431CE8D21}", BOOTSTRAPPER_ACTION_STATE_INSTALL, NULL); | 517 | ValidateExecuteExePackage(pPlan, fRollback, dwIndex++, L"{FD9920AD-DBCA-4C6C-8CD5-B47431CE8D21}", BOOTSTRAPPER_ACTION_STATE_INSTALL, NULL); |
| 504 | Assert::Equal(dwIndex, pPlan->cRollbackActions); | 518 | Assert::Equal(dwIndex, pPlan->cRollbackActions); |
| 505 | 519 | ||
| @@ -551,15 +565,17 @@ namespace Bootstrapper | |||
| 551 | fRollback = FALSE; | 565 | fRollback = FALSE; |
| 552 | dwIndex = 0; | 566 | dwIndex = 0; |
| 553 | DWORD dwExecuteCheckpointId = 1; | 567 | DWORD dwExecuteCheckpointId = 1; |
| 554 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | 568 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); |
| 555 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 569 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 570 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); | ||
| 556 | Assert::Equal(dwIndex, pPlan->cExecuteActions); | 571 | Assert::Equal(dwIndex, pPlan->cExecuteActions); |
| 557 | 572 | ||
| 558 | fRollback = TRUE; | 573 | fRollback = TRUE; |
| 559 | dwIndex = 0; | 574 | dwIndex = 0; |
| 560 | dwExecuteCheckpointId = 1; | 575 | dwExecuteCheckpointId = 1; |
| 561 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | 576 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); |
| 562 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 577 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 578 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); | ||
| 563 | Assert::Equal(dwIndex, pPlan->cRollbackActions); | 579 | Assert::Equal(dwIndex, pPlan->cRollbackActions); |
| 564 | 580 | ||
| 565 | Assert::Equal(0ul, pPlan->cExecutePackagesTotal); | 581 | Assert::Equal(0ul, pPlan->cExecutePackagesTotal); |
| @@ -609,7 +625,7 @@ namespace Bootstrapper | |||
| 609 | fRollback = FALSE; | 625 | fRollback = FALSE; |
| 610 | dwIndex = 0; | 626 | dwIndex = 0; |
| 611 | DWORD dwExecuteCheckpointId = 1; | 627 | DWORD dwExecuteCheckpointId = 1; |
| 612 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | 628 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); |
| 613 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 629 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 614 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PackageA", L"{A6F0CBF7-1578-450C-B9D7-9CF2EEC40002}", BURN_DEPENDENCY_ACTION_UNREGISTER); | 630 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PackageA", L"{A6F0CBF7-1578-450C-B9D7-9CF2EEC40002}", BURN_DEPENDENCY_ACTION_UNREGISTER); |
| 615 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 631 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| @@ -618,12 +634,13 @@ namespace Bootstrapper | |||
| 618 | ValidateExecuteMsiPackage(pPlan, fRollback, dwIndex++, L"PackageA", BOOTSTRAPPER_ACTION_STATE_UNINSTALL, BURN_MSI_PROPERTY_UNINSTALL, INSTALLUILEVEL_NONE, FALSE, BOOTSTRAPPER_MSI_FILE_VERSIONING_MISSING_OR_OLDER, 0); | 634 | ValidateExecuteMsiPackage(pPlan, fRollback, dwIndex++, L"PackageA", BOOTSTRAPPER_ACTION_STATE_UNINSTALL, BURN_MSI_PROPERTY_UNINSTALL, INSTALLUILEVEL_NONE, FALSE, BOOTSTRAPPER_MSI_FILE_VERSIONING_MISSING_OR_OLDER, 0); |
| 619 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 635 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 620 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 636 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 637 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); | ||
| 621 | Assert::Equal(dwIndex, pPlan->cExecuteActions); | 638 | Assert::Equal(dwIndex, pPlan->cExecuteActions); |
| 622 | 639 | ||
| 623 | fRollback = TRUE; | 640 | fRollback = TRUE; |
| 624 | dwIndex = 0; | 641 | dwIndex = 0; |
| 625 | dwExecuteCheckpointId = 1; | 642 | dwExecuteCheckpointId = 1; |
| 626 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | 643 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); |
| 627 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PackageA", L"{A6F0CBF7-1578-450C-B9D7-9CF2EEC40002}", BURN_DEPENDENCY_ACTION_REGISTER); | 644 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PackageA", L"{A6F0CBF7-1578-450C-B9D7-9CF2EEC40002}", BURN_DEPENDENCY_ACTION_REGISTER); |
| 628 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 645 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 629 | ValidateExecutePackageProvider(pPlan, fRollback, dwIndex++, L"PackageA", BURN_DEPENDENCY_ACTION_REGISTER); | 646 | ValidateExecutePackageProvider(pPlan, fRollback, dwIndex++, L"PackageA", BURN_DEPENDENCY_ACTION_REGISTER); |
| @@ -632,6 +649,7 @@ namespace Bootstrapper | |||
| 632 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 649 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 633 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 650 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 634 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 651 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 652 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); | ||
| 635 | Assert::Equal(dwIndex, pPlan->cRollbackActions); | 653 | Assert::Equal(dwIndex, pPlan->cRollbackActions); |
| 636 | 654 | ||
| 637 | Assert::Equal(1ul, pPlan->cExecutePackagesTotal); | 655 | Assert::Equal(1ul, pPlan->cExecutePackagesTotal); |
| @@ -682,21 +700,23 @@ namespace Bootstrapper | |||
| 682 | fRollback = FALSE; | 700 | fRollback = FALSE; |
| 683 | dwIndex = 0; | 701 | dwIndex = 0; |
| 684 | DWORD dwExecuteCheckpointId = 1; | 702 | DWORD dwExecuteCheckpointId = 1; |
| 685 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | 703 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); |
| 686 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 704 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 687 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PackageA", L"{A6F0CBF7-1578-450C-B9D7-9CF2EEC40002}", BURN_DEPENDENCY_ACTION_UNREGISTER); | 705 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PackageA", L"{A6F0CBF7-1578-450C-B9D7-9CF2EEC40002}", BURN_DEPENDENCY_ACTION_UNREGISTER); |
| 688 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 706 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 689 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 707 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 708 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); | ||
| 690 | Assert::Equal(dwIndex, pPlan->cExecuteActions); | 709 | Assert::Equal(dwIndex, pPlan->cExecuteActions); |
| 691 | 710 | ||
| 692 | fRollback = TRUE; | 711 | fRollback = TRUE; |
| 693 | dwIndex = 0; | 712 | dwIndex = 0; |
| 694 | dwExecuteCheckpointId = 1; | 713 | dwExecuteCheckpointId = 1; |
| 695 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | 714 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); |
| 696 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PackageA", L"{A6F0CBF7-1578-450C-B9D7-9CF2EEC40002}", BURN_DEPENDENCY_ACTION_REGISTER); | 715 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PackageA", L"{A6F0CBF7-1578-450C-B9D7-9CF2EEC40002}", BURN_DEPENDENCY_ACTION_REGISTER); |
| 697 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 716 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 698 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 717 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 699 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 718 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 719 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); | ||
| 700 | Assert::Equal(dwIndex, pPlan->cRollbackActions); | 720 | Assert::Equal(dwIndex, pPlan->cRollbackActions); |
| 701 | 721 | ||
| 702 | Assert::Equal(0ul, pPlan->cExecutePackagesTotal); | 722 | Assert::Equal(0ul, pPlan->cExecutePackagesTotal); |
| @@ -756,7 +776,7 @@ namespace Bootstrapper | |||
| 756 | dwIndex = 0; | 776 | dwIndex = 0; |
| 757 | DWORD dwExecuteCheckpointId = 2; | 777 | DWORD dwExecuteCheckpointId = 2; |
| 758 | BURN_EXECUTE_ACTION* pExecuteAction = NULL; | 778 | BURN_EXECUTE_ACTION* pExecuteAction = NULL; |
| 759 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | 779 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); |
| 760 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 780 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 761 | dwExecuteCheckpointId += 1; // cache checkpoints | 781 | dwExecuteCheckpointId += 1; // cache checkpoints |
| 762 | ValidateExecuteWaitCachePackage(pPlan, fRollback, dwIndex++, L"NetFx48Web"); | 782 | ValidateExecuteWaitCachePackage(pPlan, fRollback, dwIndex++, L"NetFx48Web"); |
| @@ -780,12 +800,13 @@ namespace Bootstrapper | |||
| 780 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PatchA", L"{22D1DDBA-284D-40A7-BD14-95EA07906F21}", BURN_DEPENDENCY_ACTION_REGISTER); | 800 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PatchA", L"{22D1DDBA-284D-40A7-BD14-95EA07906F21}", BURN_DEPENDENCY_ACTION_REGISTER); |
| 781 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 801 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 782 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 802 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 803 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); | ||
| 783 | Assert::Equal(dwIndex, pPlan->cExecuteActions); | 804 | Assert::Equal(dwIndex, pPlan->cExecuteActions); |
| 784 | 805 | ||
| 785 | fRollback = TRUE; | 806 | fRollback = TRUE; |
| 786 | dwIndex = 0; | 807 | dwIndex = 0; |
| 787 | dwExecuteCheckpointId = 2; | 808 | dwExecuteCheckpointId = 2; |
| 788 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | 809 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); |
| 789 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 810 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 790 | dwExecuteCheckpointId += 1; // cache checkpoints | 811 | dwExecuteCheckpointId += 1; // cache checkpoints |
| 791 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 812 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| @@ -806,6 +827,7 @@ namespace Bootstrapper | |||
| 806 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 827 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 807 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 828 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 808 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 829 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 830 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); | ||
| 809 | Assert::Equal(dwIndex, pPlan->cRollbackActions); | 831 | Assert::Equal(dwIndex, pPlan->cRollbackActions); |
| 810 | 832 | ||
| 811 | Assert::Equal(2ul, pPlan->cExecutePackagesTotal); | 833 | Assert::Equal(2ul, pPlan->cExecutePackagesTotal); |
| @@ -857,7 +879,7 @@ namespace Bootstrapper | |||
| 857 | dwIndex = 0; | 879 | dwIndex = 0; |
| 858 | DWORD dwExecuteCheckpointId = 1; | 880 | DWORD dwExecuteCheckpointId = 1; |
| 859 | BURN_EXECUTE_ACTION* pExecuteAction = NULL; | 881 | BURN_EXECUTE_ACTION* pExecuteAction = NULL; |
| 860 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | 882 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); |
| 861 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 883 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 862 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PatchA", L"{22D1DDBA-284D-40A7-BD14-95EA07906F21}", BURN_DEPENDENCY_ACTION_UNREGISTER); | 884 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PatchA", L"{22D1DDBA-284D-40A7-BD14-95EA07906F21}", BURN_DEPENDENCY_ACTION_UNREGISTER); |
| 863 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 885 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| @@ -873,12 +895,13 @@ namespace Bootstrapper | |||
| 873 | ValidateExecuteMsiPackage(pPlan, fRollback, dwIndex++, L"PackageA", BOOTSTRAPPER_ACTION_STATE_UNINSTALL, BURN_MSI_PROPERTY_UNINSTALL, INSTALLUILEVEL_NONE, FALSE, BOOTSTRAPPER_MSI_FILE_VERSIONING_MISSING_OR_OLDER, 0); | 895 | ValidateExecuteMsiPackage(pPlan, fRollback, dwIndex++, L"PackageA", BOOTSTRAPPER_ACTION_STATE_UNINSTALL, BURN_MSI_PROPERTY_UNINSTALL, INSTALLUILEVEL_NONE, FALSE, BOOTSTRAPPER_MSI_FILE_VERSIONING_MISSING_OR_OLDER, 0); |
| 874 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 896 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 875 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 897 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 898 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); | ||
| 876 | Assert::Equal(dwIndex, pPlan->cExecuteActions); | 899 | Assert::Equal(dwIndex, pPlan->cExecuteActions); |
| 877 | 900 | ||
| 878 | fRollback = TRUE; | 901 | fRollback = TRUE; |
| 879 | dwIndex = 0; | 902 | dwIndex = 0; |
| 880 | dwExecuteCheckpointId = 1; | 903 | dwExecuteCheckpointId = 1; |
| 881 | ValidateExecuteRollbackBoundary(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); | 904 | ValidateExecuteRollbackBoundaryStart(pPlan, fRollback, dwIndex++, L"WixDefaultBoundary", TRUE, FALSE); |
| 882 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PatchA", L"{22D1DDBA-284D-40A7-BD14-95EA07906F21}", BURN_DEPENDENCY_ACTION_REGISTER); | 905 | ValidateExecutePackageDependency(pPlan, fRollback, dwIndex++, L"PatchA", L"{22D1DDBA-284D-40A7-BD14-95EA07906F21}", BURN_DEPENDENCY_ACTION_REGISTER); |
| 883 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 906 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 884 | ValidateExecutePackageProvider(pPlan, fRollback, dwIndex++, L"PatchA", BURN_DEPENDENCY_ACTION_REGISTER); | 907 | ValidateExecutePackageProvider(pPlan, fRollback, dwIndex++, L"PatchA", BURN_DEPENDENCY_ACTION_REGISTER); |
| @@ -894,6 +917,7 @@ namespace Bootstrapper | |||
| 894 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 917 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 895 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 918 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 896 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); | 919 | ValidateExecuteCheckpoint(pPlan, fRollback, dwIndex++, dwExecuteCheckpointId++); |
| 920 | ValidateExecuteRollbackBoundaryEnd(pPlan, fRollback, dwIndex++); | ||
| 897 | Assert::Equal(dwIndex, pPlan->cRollbackActions); | 921 | Assert::Equal(dwIndex, pPlan->cRollbackActions); |
| 898 | 922 | ||
| 899 | Assert::Equal(2ul, pPlan->cExecutePackagesTotal); | 923 | Assert::Equal(2ul, pPlan->cExecutePackagesTotal); |
| @@ -1402,7 +1426,7 @@ namespace Bootstrapper | |||
| 1402 | Assert::Equal<BOOL>(FALSE, pAction->fDeleted); | 1426 | Assert::Equal<BOOL>(FALSE, pAction->fDeleted); |
| 1403 | } | 1427 | } |
| 1404 | 1428 | ||
| 1405 | void ValidateExecuteRollbackBoundary( | 1429 | void ValidateExecuteRollbackBoundaryStart( |
| 1406 | __in BURN_PLAN* pPlan, | 1430 | __in BURN_PLAN* pPlan, |
| 1407 | __in BOOL fRollback, | 1431 | __in BOOL fRollback, |
| 1408 | __in DWORD dwIndex, | 1432 | __in DWORD dwIndex, |
| @@ -1412,13 +1436,25 @@ namespace Bootstrapper | |||
| 1412 | ) | 1436 | ) |
| 1413 | { | 1437 | { |
| 1414 | BURN_EXECUTE_ACTION* pAction = ValidateExecuteActionExists(pPlan, fRollback, dwIndex); | 1438 | BURN_EXECUTE_ACTION* pAction = ValidateExecuteActionExists(pPlan, fRollback, dwIndex); |
| 1415 | Assert::Equal<DWORD>(BURN_EXECUTE_ACTION_TYPE_ROLLBACK_BOUNDARY, pAction->type); | 1439 | Assert::Equal<DWORD>(BURN_EXECUTE_ACTION_TYPE_ROLLBACK_BOUNDARY_START, pAction->type); |
| 1416 | NativeAssert::StringEqual(wzId, pAction->rollbackBoundary.pRollbackBoundary->sczId); | 1440 | NativeAssert::StringEqual(wzId, pAction->rollbackBoundary.pRollbackBoundary->sczId); |
| 1417 | Assert::Equal<BOOL>(fVital, pAction->rollbackBoundary.pRollbackBoundary->fVital); | 1441 | Assert::Equal<BOOL>(fVital, pAction->rollbackBoundary.pRollbackBoundary->fVital); |
| 1418 | Assert::Equal<BOOL>(fTransaction, pAction->rollbackBoundary.pRollbackBoundary->fTransaction); | 1442 | Assert::Equal<BOOL>(fTransaction, pAction->rollbackBoundary.pRollbackBoundary->fTransaction); |
| 1419 | Assert::Equal<BOOL>(FALSE, pAction->fDeleted); | 1443 | Assert::Equal<BOOL>(FALSE, pAction->fDeleted); |
| 1420 | } | 1444 | } |
| 1421 | 1445 | ||
| 1446 | void ValidateExecuteRollbackBoundaryEnd( | ||
| 1447 | __in BURN_PLAN* pPlan, | ||
| 1448 | __in BOOL fRollback, | ||
| 1449 | __in DWORD dwIndex | ||
| 1450 | ) | ||
| 1451 | { | ||
| 1452 | BURN_EXECUTE_ACTION* pAction = ValidateExecuteActionExists(pPlan, fRollback, dwIndex); | ||
| 1453 | Assert::Equal<DWORD>(BURN_EXECUTE_ACTION_TYPE_ROLLBACK_BOUNDARY_END, pAction->type); | ||
| 1454 | Assert::Equal<size_t>(NULL, (size_t)(pAction->rollbackBoundary.pRollbackBoundary)); | ||
| 1455 | Assert::Equal<BOOL>(FALSE, pAction->fDeleted); | ||
| 1456 | } | ||
| 1457 | |||
| 1422 | void ValidateExecuteUncachePackage( | 1458 | void ValidateExecuteUncachePackage( |
| 1423 | __in BURN_PLAN* pPlan, | 1459 | __in BURN_PLAN* pPlan, |
| 1424 | __in BOOL fRollback, | 1460 | __in BOOL fRollback, |
