chore(discord): add healthcheck to compose.yaml discord service

Issue #32
This commit is contained in:
2026-05-21 14:21:35 +03:00
parent feb3e08b63
commit 5b65ac4a2f
2 changed files with 22 additions and 0 deletions
@@ -93,4 +93,21 @@ public sealed class DiscordProjectStructureTests
Assert.Contains("DISCORD_BOT_TOKEN", envExample);
}
[Fact]
public void Compose_ShouldIncludeDiscordHealthcheck()
{
var repoRoot = GetRepoRoot();
var compose = File.ReadAllText(Path.Combine(repoRoot, "compose.yaml"));
var discordIndex = compose.IndexOf("discord:", StringComparison.Ordinal);
Assert.True(discordIndex >= 0, "compose.yaml should contain discord service");
var nextServiceIndex = compose.IndexOf(" web:", StringComparison.Ordinal);
var discordBlock = compose[discordIndex..nextServiceIndex];
Assert.Contains("healthcheck:", discordBlock);
Assert.Contains("test:", discordBlock);
Assert.Contains("localhost:8082/health", discordBlock);
}
}