public void ExtenstionConfig_SetToAnInvalidValue_Throws(string hostJsonContent)
        {
            File.WriteAllText(_hostJsonFile, hostJsonContent);
            Assert.True(File.Exists(_hostJsonFile));
            var configuration = BuildHostJsonConfiguration();

            ExtensionBundleOptionsSetup setup   = new ExtensionBundleOptionsSetup(configuration);
            ExtensionBundleOptions      options = new ExtensionBundleOptions();
            var ex = Assert.Throws <ArgumentException>(() => setup.Configure(options));

            Assert.StartsWith($"The value of id property in extensionBundle section of {ScriptConstants.HostMetadataFileName} file is invalid or missing.", ex.Message);
        }
        public void MissingOrValidExtenstionConfig_DoesNotThrowException(string hostJsonContent)
        {
            File.WriteAllText(_hostJsonFile, hostJsonContent);
            Assert.True(File.Exists(_hostJsonFile));
            var configuration = BuildHostJsonConfiguration();

            ExtensionBundleOptionsSetup setup   = new ExtensionBundleOptionsSetup(configuration);
            ExtensionBundleOptions      options = new ExtensionBundleOptions();
            var ex = Record.Exception(() => setup.Configure(options));

            Assert.Null(ex);
        }