Add data management, randomized HTML drip and public README
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
3671019e60
commit
f5d8ca7484
46 files changed
+1601
-172
No files matched your search
@@ -1,6 +1,5 @@
|
||||
using Flypaper.Core;
|
||||
using Flypaper.Core.Settings;
|
||||
using Flypaper.Core.Strategies;
|
||||
using Flypaper.Http;
|
||||
using Flypaper.Http.Matching;
|
||||
using Flypaper.Storage;
|
||||
@@ -74,16 +73,16 @@ public sealed class SettingsOverrideTests : IDisposable
|
||||
|
||||
await store.SaveAsync(new RuntimeSettings(
|
||||
["/custom"],
|
||||
TimeSpan.FromSeconds(3),
|
||||
50,
|
||||
4,
|
||||
TimeSpan.FromMinutes(10),
|
||||
["extra.example"]));
|
||||
["extra.example"],
|
||||
90,
|
||||
true));
|
||||
|
||||
matcher.Match("dashboard.lan", "/custom").ShouldBe(TrapMatch.TrapPath);
|
||||
matcher.Match("dashboard.lan", "/.env").ShouldBe(TrapMatch.None);
|
||||
matcher.Match("extra.example", "/").ShouldBe(TrapMatch.None);
|
||||
host.Services.GetRequiredService<IOptionsMonitor<DripOptions>>().CurrentValue.Interval.ShouldBe(TimeSpan.FromSeconds(3));
|
||||
(await store.HasOverridesAsync()).ShouldBeTrue();
|
||||
|
||||
await store.ResetAsync();
|
||||
@@ -102,11 +101,12 @@ public sealed class SettingsOverrideTests : IDisposable
|
||||
|
||||
await host.Services.GetRequiredService<RuntimeSettingsStore>().SaveAsync(new RuntimeSettings(
|
||||
[],
|
||||
TimeSpan.FromSeconds(3),
|
||||
50,
|
||||
4,
|
||||
TimeSpan.FromMinutes(10),
|
||||
[]));
|
||||
[],
|
||||
90,
|
||||
true));
|
||||
|
||||
matcher.Match("dashboard.lan", "/.env").ShouldBe(TrapMatch.None);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user