diff options
Diffstat (limited to 'src/test/burn/TestBA/TestBA.cs')
-rw-r--r-- | src/test/burn/TestBA/TestBA.cs | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/test/burn/TestBA/TestBA.cs b/src/test/burn/TestBA/TestBA.cs index fdbcc6d4..b4d74341 100644 --- a/src/test/burn/TestBA/TestBA.cs +++ b/src/test/burn/TestBA/TestBA.cs | |||
@@ -27,6 +27,7 @@ namespace WixToolset.Test.BA | |||
27 | 27 | ||
28 | private string updateBundlePath; | 28 | private string updateBundlePath; |
29 | 29 | ||
30 | private bool forceKeepRegistration; | ||
30 | private bool immediatelyQuit; | 31 | private bool immediatelyQuit; |
31 | private bool quitAfterDetect; | 32 | private bool quitAfterDetect; |
32 | private bool explicitlyElevateAndPlanFromOnElevateBegin; | 33 | private bool explicitlyElevateAndPlanFromOnElevateBegin; |
@@ -131,6 +132,12 @@ namespace WixToolset.Test.BA | |||
131 | this.explicitlyElevateAndPlanFromOnElevateBegin = false; | 132 | this.explicitlyElevateAndPlanFromOnElevateBegin = false; |
132 | } | 133 | } |
133 | 134 | ||
135 | string forceKeepRegistration = this.ReadPackageAction(null, "ForceKeepRegistration"); | ||
136 | if (String.IsNullOrEmpty(forceKeepRegistration) || !Boolean.TryParse(forceKeepRegistration, out this.forceKeepRegistration)) | ||
137 | { | ||
138 | this.forceKeepRegistration = false; | ||
139 | } | ||
140 | |||
134 | string quitAfterDetect = this.ReadPackageAction(null, "QuitAfterDetect"); | 141 | string quitAfterDetect = this.ReadPackageAction(null, "QuitAfterDetect"); |
135 | if (String.IsNullOrEmpty(quitAfterDetect) || !Boolean.TryParse(quitAfterDetect, out this.quitAfterDetect)) | 142 | if (String.IsNullOrEmpty(quitAfterDetect) || !Boolean.TryParse(quitAfterDetect, out this.quitAfterDetect)) |
136 | { | 143 | { |
@@ -533,6 +540,16 @@ namespace WixToolset.Test.BA | |||
533 | this.ShutdownUiThread(); | 540 | this.ShutdownUiThread(); |
534 | } | 541 | } |
535 | 542 | ||
543 | protected override void OnUnregisterBegin(UnregisterBeginEventArgs args) | ||
544 | { | ||
545 | if (this.forceKeepRegistration && args.RegistrationType == RegistrationType.None) | ||
546 | { | ||
547 | args.RegistrationType = RegistrationType.InProgress; | ||
548 | } | ||
549 | |||
550 | this.Log("OnUnregisterBegin, default: {0}, requested: {1}", args.RecommendedRegistrationType, args.RegistrationType); | ||
551 | } | ||
552 | |||
536 | private void TestVariables() | 553 | private void TestVariables() |
537 | { | 554 | { |
538 | // First make sure we can check and get standard variables of each type. | 555 | // First make sure we can check and get standard variables of each type. |