public void TestGcpOutputWindow_Initalized()
        {
            var exportProvider = new FakeExportProvider <IGcpOutputWindow>();

            ComponentModelMock.Setup(s => s.DefaultExportProvider).Returns(exportProvider);

            RunPackageInitalize();
            Assert.AreEqual(exportProvider.MockedValue, _objectUnderTest.GcpOutputWindow);
        }
        public async Task TestDataSourceFactory_Initialized()
        {
            var exportProvider = new FakeExportProvider <IDataSourceFactory>();

            ComponentModelMock.Setup(s => s.DefaultExportProvider).Returns(exportProvider);

            await RunPackageInitializeAsync();

            Assert.AreEqual(exportProvider.MockedValue, _objectUnderTest.DataSourceFactory);
        }
        public async Task TestUserPromptService_Initialized()
        {
            var exportProvider = new FakeExportProvider <IUserPromptService>();

            ComponentModelMock.Setup(s => s.DefaultExportProvider).Returns(exportProvider);

            await RunPackageInitializeAsync();

            Assert.AreEqual(exportProvider.MockedValue, _objectUnderTest.UserPromptService);
        }
Exemple #4
0
        public async Task TestShellUtils_Initalized()
        {
            var exportProvider = new FakeExportProvider <IShellUtils>();

            ComponentModelMock.Setup(s => s.DefaultExportProvider).Returns(exportProvider);

            await RunPackageInitalizeAsync();

            Assert.AreEqual(exportProvider.MockedValue, _objectUnderTest.ShellUtils);
        }
        public void TestStatusbarHelper_Initalized()
        {
            var exportProvider = new FakeExportProvider <IStatusbarService>();

            ComponentModelMock.Setup(s => s.DefaultExportProvider).Returns(exportProvider);

            RunPackageInitalize();

            Assert.AreEqual(exportProvider.MockedValue, _objectUnderTest.StatusbarHelper);
        }
        public async Task TestGetMefServiceLazy_GetsLazyServiceFromMef()
        {
            var exportProvider = new FakeExportProvider <IFileSystem>();

            ComponentModelMock.Setup(s => s.DefaultExportProvider).Returns(exportProvider);
            await RunPackageInitializeAsync();

            Lazy <IFileSystem> service = _objectUnderTest.GetMefServiceLazy <IFileSystem>();

            Assert.AreEqual(exportProvider.MockedValue, service.Value);
        }