diff options
Diffstat (limited to 'src/test/burn/WixTestTools/BundleVerifier.cs')
-rw-r--r-- | src/test/burn/WixTestTools/BundleVerifier.cs | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/src/test/burn/WixTestTools/BundleVerifier.cs b/src/test/burn/WixTestTools/BundleVerifier.cs index 103171cd..ff45a291 100644 --- a/src/test/burn/WixTestTools/BundleVerifier.cs +++ b/src/test/burn/WixTestTools/BundleVerifier.cs | |||
@@ -80,6 +80,29 @@ namespace WixTestTools | |||
80 | File.Delete(expectedCachePath); | 80 | File.Delete(expectedCachePath); |
81 | } | 81 | } |
82 | 82 | ||
83 | public bool TryGetArpEntryExePackageConfiguration(string packageId, out string arpId, out string arpVersion, out bool arpWin64, out bool perMachine) | ||
84 | { | ||
85 | using var wixOutput = WixOutput.Read(this.BundlePdb); | ||
86 | var intermediate = Intermediate.Load(wixOutput); | ||
87 | var section = intermediate.Sections.Single(); | ||
88 | var packageSymbol = section.Symbols.OfType<WixBundlePackageSymbol>().SingleOrDefault(p => p.Id.Id == packageId); | ||
89 | var exePackageSymbol = section.Symbols.OfType<WixBundleExePackageSymbol>().SingleOrDefault(p => p.Id.Id == packageId); | ||
90 | if (packageSymbol == null || exePackageSymbol == null || exePackageSymbol.DetectionType != WixBundleExePackageDetectionType.Arp) | ||
91 | { | ||
92 | arpId = null; | ||
93 | arpVersion = null; | ||
94 | arpWin64 = false; | ||
95 | perMachine = false; | ||
96 | return false; | ||
97 | } | ||
98 | |||
99 | arpId = exePackageSymbol.ArpId; | ||
100 | arpVersion = exePackageSymbol.ArpDisplayVersion; | ||
101 | arpWin64 = exePackageSymbol.ArpWin64; | ||
102 | perMachine = packageSymbol.PerMachine == true; | ||
103 | return true; | ||
104 | } | ||
105 | |||
83 | public bool TryGetRegistration(out BundleRegistration registration) | 106 | public bool TryGetRegistration(out BundleRegistration registration) |
84 | { | 107 | { |
85 | var bundleSymbol = this.GetBundleSymbol(); | 108 | var bundleSymbol = this.GetBundleSymbol(); |