Allow solutions to store extra reagent data (#19323)
This commit is contained in:
@@ -79,9 +79,9 @@ namespace Content.IntegrationTests.Tests.Chemistry
|
||||
var foundProductsMap = reactionPrototype.Products
|
||||
.Concat(reactionPrototype.Reactants.Where(x => x.Value.Catalyst).ToDictionary(x => x.Key, x => x.Value.Amount))
|
||||
.ToDictionary(x => x, _ => false);
|
||||
foreach (var reagent in component.Contents)
|
||||
foreach (var (reagent, quantity) in component.Contents)
|
||||
{
|
||||
Assert.That(foundProductsMap.TryFirstOrNull(x => x.Key.Key == reagent.ReagentId && x.Key.Value == reagent.Quantity, out var foundProduct));
|
||||
Assert.That(foundProductsMap.TryFirstOrNull(x => x.Key.Key == reagent.Prototype && x.Key.Value == quantity, out var foundProduct));
|
||||
foundProductsMap[foundProduct.Value.Key] = true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user