Files
RobustToolbox/Robust.Shared.IntegrationTests/Configuration/ConfigurationIntegrationTest.cs
PJB3005 788e9386fd Split up test project
Robust.UnitTesting was both ALL tests for RT, and also API surface for content tests.

Tests are now split into separate projects as appropriate, and the API side has also been split off.
2025-12-16 01:36:53 +01:00

44 lines
1.2 KiB
C#

using System.Threading.Tasks;
using NUnit.Framework;
using Robust.Shared.Configuration;
using Robust.Shared.IntegrationTests.Configuration;
using Robust.Shared.Log;
namespace Robust.UnitTesting.Shared.Configuration;
[Parallelizable(ParallelScope.All)]
[TestFixture]
[TestOf(typeof(ConfigurationManagerTest))]
internal sealed class ConfigurationIntegrationTest : RobustIntegrationTest
{
[Test]
public async Task TestSaveNoWarningServer()
{
using var server = StartServer(new ServerIntegrationOptions
{
FailureLogLevel = LogLevel.Warning
});
await server.WaitPost(() =>
{
// ReSharper disable once AccessToDisposedClosure
var cfg = server.Resolve<IConfigurationManager>();
cfg.SaveToFile();
});
}
[Test]
public async Task TestSaveNoWarningClient()
{
using var server = StartClient(new ClientIntegrationOptions
{
FailureLogLevel = LogLevel.Warning
});
await server.WaitPost(() =>
{
// ReSharper disable once AccessToDisposedClosure
var cfg = server.Resolve<IConfigurationManager>();
cfg.SaveToFile();
});
}
}