Refactor project files for improved readability and structure
- Cleaned up whitespace in Directory.Build.props and Directory.Packages.props for consistency. - Reformatted project file references in PnvPanel.Api.csproj for better clarity. - Enhanced code readability in various endpoint files by adjusting line breaks and indentation. - Standardized method signatures and improved formatting in ResultExtensions and multiple endpoint classes for better maintainability.
This commit is contained in:
+17
-13
@@ -42,20 +42,24 @@ public sealed class PnvPanelWebApplicationFactory : WebApplicationFactory<Progra
|
||||
{
|
||||
builder.UseEnvironment("Development");
|
||||
|
||||
builder.ConfigureAppConfiguration((_, config) =>
|
||||
{
|
||||
config.AddInMemoryCollection(new Dictionary<string, string?>
|
||||
builder.ConfigureAppConfiguration(
|
||||
(_, config) =>
|
||||
{
|
||||
["ConnectionStrings:Default"] = _postgres.GetConnectionString(),
|
||||
["AdminSeed:Username"] = AdminUserName,
|
||||
["AdminSeed:Password"] = AdminPassword,
|
||||
// Пусто — TelegramBotHostedService при пустом токене не стартует (см. Api/Telegram/TelegramBotHostedService.cs).
|
||||
["Telegram:BotToken"] = "",
|
||||
// Весь collection делит один TestServer/host — все запросы идут от одного "клиента",
|
||||
// дефолтный лимит 20/мин быстро исчерпывается. Поднимаем для тестового окружения.
|
||||
["RateLimiting:AuthPermitLimit"] = "10000",
|
||||
});
|
||||
});
|
||||
config.AddInMemoryCollection(
|
||||
new Dictionary<string, string?>
|
||||
{
|
||||
["ConnectionStrings:Default"] = _postgres.GetConnectionString(),
|
||||
["AdminSeed:Username"] = AdminUserName,
|
||||
["AdminSeed:Password"] = AdminPassword,
|
||||
// Пусто — TelegramBotHostedService при пустом токене не стартует (см. Api/Telegram/TelegramBotHostedService.cs).
|
||||
["Telegram:BotToken"] = "",
|
||||
// Весь collection делит один TestServer/host — все запросы идут от одного "клиента",
|
||||
// дефолтный лимит 20/мин быстро исчерпывается. Поднимаем для тестового окружения.
|
||||
["RateLimiting:AuthPermitLimit"] = "10000",
|
||||
}
|
||||
);
|
||||
}
|
||||
);
|
||||
|
||||
builder.ConfigureServices(services =>
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user