mirror of
https://github.com/ckaczor/sqltoolsservice.git
synced 2026-01-14 01:25:40 -05:00
* Add linting for copyright and unused usings * Add one more + comment * Enforce in build and fix errors * Fix build
50 lines
1.7 KiB
C#
50 lines
1.7 KiB
C#
//
|
|
// Copyright (c) Microsoft. All rights reserved.
|
|
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
|
//
|
|
|
|
using System;
|
|
using System.Threading.Tasks;
|
|
using Microsoft.SqlTools.ResourceProvider.Core;
|
|
using Microsoft.SqlTools.ResourceProvider.Core.Authentication;
|
|
using Microsoft.SqlTools.ResourceProvider.Core.Extensibility;
|
|
|
|
namespace Microsoft.SqlTools.ServiceLayer.UnitTests.ResourceProvider.Azure
|
|
{
|
|
/// <summary>
|
|
/// A fake server discovery class
|
|
/// </summary>
|
|
[Exportable(ServerTypes.SqlServer, Categories.Azure
|
|
, typeof(IServerDiscoveryProvider),
|
|
"Microsoft.SqlTools.ServiceLayer.UnitTests.ResourceProvider.Azure.FakeAzureServerDiscoveryProvider", 1)]
|
|
public class FakeAzureServerDiscoveryProvider : ExportableBase, IServerDiscoveryProvider, ISecureService
|
|
{
|
|
public FakeAzureServerDiscoveryProvider()
|
|
{
|
|
Metadata = new ExportableMetadata(ServerTypes.SqlServer, Categories.Azure,
|
|
"Microsoft.SqlTools.ServiceLayer.UnitTests.ResourceProvider.Azure.FakeAzureServerDiscoveryProvider", 1);
|
|
}
|
|
public Task<ServiceResponse<ServerInstanceInfo>> GetServerInstancesAsync()
|
|
{
|
|
throw new NotImplementedException();
|
|
}
|
|
|
|
public IAccountManager AccountManager
|
|
{
|
|
get;
|
|
set;
|
|
}
|
|
|
|
/// <summary>
|
|
/// This should always return null otherwise there's going to be a infinite loop
|
|
/// </summary>
|
|
public IServerDiscoveryProvider ServerDiscoveryProvider
|
|
{
|
|
get
|
|
{
|
|
return GetService<IServerDiscoveryProvider>();
|
|
}
|
|
}
|
|
}
|
|
}
|