Create MS.SqlTools.Credentials project (#249)

* Initial credential service files

* Clean-up hostloader

* Update build scripts to build credentials archive

* Move hosting files to new assembly

* Add credentials files to MS.SqlTools.Credentials

* Remove duplicate files

* Update namespace in program.cs

* Fix test build breaks

* Update extensions visibility.

* Remove unused resource strings

* Add xproj files to SLN for appveyor builds

* Fix appveyor build break in test project

* Fix extensibility tests

* Fix various typos in latest iteration

* Add settings for Integration build

* Fix codecoverage.bat to use full pdb for new projects

* Fix bug when packing in folder with native images

* Fix typos in xproj

* Reset XLF to fix build.cmd
This commit is contained in:
Karl Burtram
2017-02-23 16:09:58 -08:00
committed by GitHub
parent e79a37bdfe
commit 0af7bef66d
112 changed files with 4887 additions and 1870 deletions

View File

@@ -29,28 +29,27 @@ namespace Microsoft.SqlTools.ServiceLayer.Test.Extensibility
}
[Fact]
public void CreateDefaultLoaderShouldOnlyFindTypesInMainAssembly()
public void CreateDefaultLoaderShouldFindTypesOnlyInMainAssembly()
{
// Given a store created using CreateDefaultLoader
// Then should not find exports from a different assembly
// Then not should find exports from a different assembly
ExtensionStore store = ExtensionStore.CreateDefaultLoader<MyExportType>();
Assert.Equal(0, store.GetExports<MyExportType>().Count());
// But should find exports that are defined in the main assembly
// And should not find exports that are defined in the ServiceLayer assembly
store = ExtensionStore.CreateDefaultLoader<ASTNodeFormatterFactory>();
Assert.NotEmpty(store.GetExports<ASTNodeFormatterFactory>());
Assert.Empty(store.GetExports<ASTNodeFormatterFactory>());
}
[Fact]
public void CreateDefaultServiceProviderShouldOnlyFindTypesInMainAssembly()
public void CreateDefaultServiceProviderShouldFindTypesInAllAssemblies()
{
// Given a default ExtensionServiceProvider
// Then should not find exports from a different assembly
ExtensionServiceProvider serviceProvider = ExtensionServiceProvider.CreateDefaultServiceProvider();
Assert.Empty(serviceProvider.GetServices<MyExportType>());
Assert.NotEmpty(serviceProvider.GetServices<MyExportType>());
// But should find exports that are defined in the main assembly
// But should find exports that are defined in the main assembly
Assert.NotEmpty(serviceProvider.GetServices<ASTNodeFormatterFactory>());
}