ci: validate portable tests on macos

This commit is contained in:
dh
2026-09-16 08:30:56 +02:00
parent 0e2aa3830f
commit d1d4b53ee8
7 changed files with 99 additions and 23 deletions
@@ -110,6 +110,11 @@ public sealed class AzureSpeechStreamingTranscriptionProviderTests
[Fact]
public void ResolveKeyFallsBackToUserEnvironment()
{
if (!OperatingSystem.IsWindows())
{
return;
}
var keyEnv = $"MEETING_ASSISTANT_AZURE_KEY_{Guid.NewGuid():N}";
try
{
@@ -206,7 +206,7 @@ public sealed class MeetingNoteStoreTests
{
var link = MeetingNoteActionLinks.CreateSummaryRetryLink(
"http://localhost:5090/",
"C:\\Vault\\Meetings\\Summaries\\summary with spaces.md");
Path.Combine(Path.GetTempPath(), "summary with spaces.md"));
Assert.Equal(
"[Retry summary generation](http://localhost:5090/meetings/summary/retry?summaryPath=summary%20with%20spaces.md)",
@@ -448,9 +448,14 @@ public sealed class RecordingCoordinatorTests
[Fact]
public async Task StartCreatesMeetingNoteLinkedToTranscriptAndOpensIt()
{
var vaultRoot = Path.Combine(Path.GetTempPath(), "meeting-assistant-vault");
var transcriptPath = Path.Combine(vaultRoot, "Meetings", "Transcripts", "20260519-transcript.md");
var meetingNotePath = Path.Combine(vaultRoot, "Meetings", "Notes", "20260519-meeting.md");
var assistantContextFolder = Path.Combine(vaultRoot, "Meetings", "Assistant Context");
var summariesFolder = Path.Combine(vaultRoot, "Meetings", "Summaries");
var audioSource = new ControlledAudioSource();
var transcriptStore = new InMemoryTranscriptStore("C:\\Vault\\Meetings\\Transcripts\\20260519-transcript.md");
var noteStore = new InMemoryMeetingNoteStore("C:\\Vault\\Meetings\\Notes\\20260519-meeting.md");
var transcriptStore = new InMemoryTranscriptStore(transcriptPath);
var noteStore = new InMemoryMeetingNoteStore(meetingNotePath);
var clock = new ManualMeetingInactivityClock(DateTimeOffset.Parse("2026-05-19T10:03:42+02:00"));
var noteOpener = new CapturingMeetingNoteOpener();
var artifactStore = new InMemoryMeetingArtifactStore();
@@ -468,25 +473,27 @@ public sealed class RecordingCoordinatorTests
{
Vault = new VaultOptions
{
AssistantContextFolder = "C:\\Vault\\Meetings\\Assistant Context",
SummariesFolder = "C:\\Vault\\Meetings\\Summaries"
AssistantContextFolder = assistantContextFolder,
SummariesFolder = summariesFolder
}
}),
NullLogger<MeetingRecordingCoordinator>.Instance,
inactivityClock: clock);
var status = await coordinator.StartAsync(CancellationToken.None);
var assistantContextPath = Path.Combine(assistantContextFolder, "20260519-1003-context.md");
var summaryPath = Path.Combine(summariesFolder, "20260519-1003-summary.md");
Assert.True(status.IsRecording);
Assert.Equal("C:\\Vault\\Meetings\\Notes\\20260519-meeting.md", status.MeetingNotePath);
Assert.Equal("C:\\Vault\\Meetings\\Transcripts\\20260519-transcript.md", noteStore.SavedNote?.Frontmatter.Transcript);
Assert.Equal("C:\\Vault\\Meetings\\Assistant Context\\20260519-1003-context.md", noteStore.SavedNote?.Frontmatter.AssistantContext);
Assert.Equal("C:\\Vault\\Meetings\\Summaries\\20260519-1003-summary.md", noteStore.SavedNote?.Frontmatter.Summary);
Assert.Equal("C:\\Vault\\Meetings\\Notes\\20260519-meeting.md", noteOpener.OpenedPath);
Assert.Equal("C:\\Vault\\Meetings\\Notes\\20260519-meeting.md", artifactStore.CreatedArtifacts?.MeetingNotePath);
Assert.Equal("C:\\Vault\\Meetings\\Transcripts\\20260519-transcript.md", artifactStore.CreatedArtifacts?.TranscriptPath);
Assert.Equal("C:\\Vault\\Meetings\\Assistant Context\\20260519-1003-context.md", artifactStore.CreatedArtifacts?.AssistantContextPath);
Assert.Equal("C:\\Vault\\Meetings\\Summaries\\20260519-1003-summary.md", artifactStore.CreatedArtifacts?.SummaryPath);
Assert.Equal(meetingNotePath, status.MeetingNotePath);
Assert.Equal(transcriptPath, noteStore.SavedNote?.Frontmatter.Transcript);
Assert.Equal(assistantContextPath, noteStore.SavedNote?.Frontmatter.AssistantContext);
Assert.Equal(summaryPath, noteStore.SavedNote?.Frontmatter.Summary);
Assert.Equal(meetingNotePath, noteOpener.OpenedPath);
Assert.Equal(meetingNotePath, artifactStore.CreatedArtifacts?.MeetingNotePath);
Assert.Equal(transcriptPath, artifactStore.CreatedArtifacts?.TranscriptPath);
Assert.Equal(assistantContextPath, artifactStore.CreatedArtifacts?.AssistantContextPath);
Assert.Equal(summaryPath, artifactStore.CreatedArtifacts?.SummaryPath);
Assert.Equal(noteStore.SavedNote?.Frontmatter.Title, artifactStore.ContextMeetingNote?.Frontmatter.Title);
Assert.Equal(noteStore.SavedNote?.Frontmatter.StartTime, artifactStore.ContextMeetingNote?.Frontmatter.StartTime);
@@ -181,6 +181,11 @@ public sealed class TaskbarIconTests
[SupportedOSPlatform("windows")]
public void TaskbarIconGlyphsAreVisuallyCentered()
{
if (!OperatingSystem.IsWindows())
{
return;
}
foreach (var state in new[]
{
RecordingProcessState.Idle,
+9 -8
View File
@@ -7,16 +7,16 @@ public sealed class VaultPathTests
[Fact]
public void ResolveUsesVaultBaseFolderForRelativePaths()
{
var baseFolder = Path.Combine(Path.GetTempPath(), "meeting-assistant-vault");
var vault = new VaultOptions
{
BaseFolder = @"C:\Users\masc3\OpenCloud\Persönlich\Vault\Exxeta"
BaseFolder = baseFolder
};
var resolved = VaultPath.Resolve(vault, @"Meetings\Transcripts");
var relativePath = Path.Combine("Meetings", "Transcripts");
var resolved = VaultPath.Resolve(vault, relativePath);
Assert.Equal(
@"C:\Users\masc3\OpenCloud\Persönlich\Vault\Exxeta\Meetings\Transcripts",
resolved);
Assert.Equal(Path.Combine(baseFolder, relativePath), resolved);
}
[Fact]
@@ -24,11 +24,12 @@ public sealed class VaultPathTests
{
var vault = new VaultOptions
{
BaseFolder = @"C:\Users\masc3\OpenCloud\Persönlich\Vault\Exxeta"
BaseFolder = Path.Combine(Path.GetTempPath(), "meeting-assistant-vault")
};
var absolutePath = Path.Combine(Path.GetTempPath(), "meeting-assistant-other");
var resolved = VaultPath.Resolve(vault, @"C:\Other\Path");
var resolved = VaultPath.Resolve(vault, absolutePath);
Assert.Equal(@"C:\Other\Path", resolved);
Assert.Equal(absolutePath, resolved);
}
}