Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
using Microsoft.CodeAnalysis.Razor.Logging;
using Microsoft.VisualStudio.LanguageServer.Protocol;

namespace Microsoft.AspNetCore.Razor.LanguageServer.Completion;
namespace Microsoft.CodeAnalysis.Razor.Completion;

internal class AggregateCompletionItemResolver
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
using System.Threading.Tasks;
using Microsoft.VisualStudio.LanguageServer.Protocol;

namespace Microsoft.AspNetCore.Razor.LanguageServer.Completion;
namespace Microsoft.CodeAnalysis.Razor.Completion;

internal abstract class CompletionItemResolver
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,13 @@
using System.Linq;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Razor.LanguageServer.ProjectSystem;
using Microsoft.CodeAnalysis;
using Microsoft.CodeAnalysis.Razor.Completion;
using Microsoft.CodeAnalysis.Razor.ProjectSystem;
using Microsoft.CodeAnalysis.Razor.Tooltip;
using Microsoft.VisualStudio.LanguageServer.Protocol;
using Microsoft.VisualStudio.Text.Adornments;

namespace Microsoft.AspNetCore.Razor.LanguageServer.Completion;
namespace Microsoft.CodeAnalysis.Razor.Completion;

internal class RazorCompletionItemResolver(IProjectSnapshotManager projectManager) : CompletionItemResolver
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,8 @@
using System.Collections.Generic;
using System.Collections.Immutable;
using Microsoft.AspNetCore.Razor.PooledObjects;
using Microsoft.AspNetCore.Razor.Utilities;
using Microsoft.CodeAnalysis.Razor.ProjectSystem;

namespace Microsoft.AspNetCore.Razor.LanguageServer.ProjectSystem;
namespace Microsoft.CodeAnalysis.Razor.ProjectSystem;

internal static partial class IProjectSnapshotManagerExtensions
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,9 @@
using System.Linq;
using Microsoft.AspNetCore.Razor.PooledObjects;
using Microsoft.AspNetCore.Razor.Utilities;
using Microsoft.CodeAnalysis.Razor;
using Microsoft.CodeAnalysis.Razor.Logging;
using Microsoft.CodeAnalysis.Razor.ProjectSystem;

namespace Microsoft.AspNetCore.Razor.LanguageServer.ProjectSystem;
namespace Microsoft.CodeAnalysis.Razor.ProjectSystem;

internal static partial class IProjectSnapshotManagerExtensions
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,9 @@
using System.IO;
using Microsoft.AspNetCore.Razor.Language;
using Microsoft.AspNetCore.Razor.Utilities;
using Microsoft.CodeAnalysis.Razor;
using Microsoft.CodeAnalysis.Razor.ProjectSystem;
using Microsoft.Extensions.Internal;

namespace Microsoft.AspNetCore.Razor.LanguageServer.ProjectSystem;
namespace Microsoft.CodeAnalysis.Razor.ProjectSystem;

internal sealed record class MiscFilesHostProject : HostProject
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@
using Microsoft.AspNetCore.Razor.ProjectSystem;
using Microsoft.AspNetCore.Razor.Test.Common;
using Microsoft.CodeAnalysis.Razor.ProjectSystem;
using Microsoft.CodeAnalysis.Razor.Workspaces.Test;
using Roslyn.Test.Utilities;
using Xunit;
using Xunit.Abstractions;
using static Microsoft.AspNetCore.Razor.Language.CommonMetadata;
using IProjectSnapshotManagerExtensions = Microsoft.CodeAnalysis.Razor.Workspaces.Test.IProjectSnapshotManagerExtensions;

namespace Microsoft.CodeAnalysis.Razor.Tooltip;

Expand All @@ -22,7 +22,7 @@ public class ProjectAvailabilityTests(ITestOutputHelper testOutput) : ToolingTes
public async Task GetProjectAvailabilityText_NoProjects_ReturnsNull()
{
var projectManager = CreateProjectSnapshotManager();
var solutionQueryOperations = projectManager.GetQueryOperations();
var solutionQueryOperations = IProjectSnapshotManagerExtensions.GetQueryOperations(projectManager);

var availability = await solutionQueryOperations.GetProjectAvailabilityTextAsync("file.razor", "MyTagHelper", DisposalToken);

Expand Down Expand Up @@ -60,7 +60,7 @@ await projectManager.UpdateAsync(updater =>
updater.DocumentAdded(hostProject.Key, hostDocument, TestMocks.CreateTextLoader(hostDocument.FilePath, text: ""));
});

var solutionQueryOperations = projectManager.GetQueryOperations();
var solutionQueryOperations = IProjectSnapshotManagerExtensions.GetQueryOperations(projectManager);

var availability = await solutionQueryOperations.GetProjectAvailabilityTextAsync(hostDocument.FilePath, tagHelperTypeName, DisposalToken);

Expand Down Expand Up @@ -109,7 +109,7 @@ await projectManager.UpdateAsync(updater =>
updater.DocumentAdded(hostProject2.Key, hostDocument, TestMocks.CreateTextLoader(hostDocument.FilePath, text: ""));
});

var solutionQueryOperations = projectManager.GetQueryOperations();
var solutionQueryOperations = IProjectSnapshotManagerExtensions.GetQueryOperations(projectManager);

var availability = await solutionQueryOperations.GetProjectAvailabilityTextAsync(hostDocument.FilePath, tagHelperTypeName, DisposalToken);

Expand Down Expand Up @@ -157,7 +157,7 @@ await projectManager.UpdateAsync(updater =>
updater.DocumentAdded(hostProject2.Key, hostDocument, TestMocks.CreateTextLoader(hostDocument.FilePath, text: ""));
});

var solutionQueryOperations = projectManager.GetQueryOperations();
var solutionQueryOperations = IProjectSnapshotManagerExtensions.GetQueryOperations(projectManager);

var availability = await solutionQueryOperations.GetProjectAvailabilityTextAsync(hostDocument.FilePath, tagHelperTypeName, DisposalToken);

Expand Down Expand Up @@ -201,7 +201,7 @@ await projectManager.UpdateAsync(updater =>
updater.DocumentAdded(hostProject2.Key, hostDocument, TestMocks.CreateTextLoader(hostDocument.FilePath, text: ""));
});

var solutionQueryOperations = projectManager.GetQueryOperations();
var solutionQueryOperations = IProjectSnapshotManagerExtensions.GetQueryOperations(projectManager);

var availability = await solutionQueryOperations.GetProjectAvailabilityTextAsync(hostDocument.FilePath, "MyTagHelper", DisposalToken);

Expand Down