Fix engine integration tests not generating Net IDs.

This commit is contained in:
Vera Aguilera Puerto
2021-07-12 10:42:38 +02:00
parent b67d24efee
commit 8b013cb424

View File

@@ -430,8 +430,12 @@ namespace Robust.UnitTesting
};
// Autoregister components if options are null or we're NOT starting from content.
if(!_options?.ContentStart ?? true)
IoCManager.Resolve<IComponentFactory>().DoAutoRegistrations();
if (!_options?.ContentStart ?? true)
{
var componentFactory = IoCManager.Resolve<IComponentFactory>();
componentFactory.DoAutoRegistrations();
componentFactory.GenerateNetIds();
}
if (_options?.ContentAssemblies != null)
{
@@ -551,8 +555,12 @@ namespace Robust.UnitTesting
};
// Autoregister components if options are null or we're NOT starting from content.
if(!_options?.ContentStart ?? true)
IoCManager.Resolve<IComponentFactory>().DoAutoRegistrations();
if (!_options?.ContentStart ?? true)
{
var componentFactory = IoCManager.Resolve<IComponentFactory>();
componentFactory.DoAutoRegistrations();
componentFactory.GenerateNetIds();
}
if (_options?.ContentAssemblies != null)
{