diff --git a/Content.IntegrationTests/Utility/GameDataScrounger.cs b/Content.IntegrationTests/Utility/GameDataScrounger.cs
index bb190fbe21..feaaa9e930 100644
--- a/Content.IntegrationTests/Utility/GameDataScrounger.cs
+++ b/Content.IntegrationTests/Utility/GameDataScrounger.cs
@@ -169,17 +169,15 @@ public static partial class GameDataScrounger
// Take a directory off the stack.
var dir = explorationStack.Pop();
- if (ignoreList.Contains(Path.GetFullPath(dir)))
- continue; // It's all abstract anyway.
+ var ignoredDir = ignoreList.Contains(Path.GetFullPath(dir));
explorationStack.AddRange(Directory.EnumerateDirectories(dir));
foreach (var file in Directory.EnumerateFiles(dir, "*.yml"))
{
- if (ignoreList.Contains(Path.GetFullPath(file)))
- continue; // It's all abstract anyway.
+ var ignored = ignoredDir || ignoreList.Contains(Path.GetFullPath(file));
- foreach (var (kind, id) in IndexPrototypesIn(file))
+ foreach (var (kind, id) in IndexPrototypesIn(file, ignored))
{
// alternate universe where .net has rust's Entry api.
if (!_prototypeIndex.TryGetValue(kind, out var list))
@@ -204,8 +202,9 @@ public static partial class GameDataScrounger
/// yielding all (type, id) pairs.
///
/// The file to index.
+ /// Whether or not the file is ignored. This treats the entire file as abstract.
/// An enumerator of all prototypes in the file, regardless of kind.
- private static IEnumerable<(string type, string id)> IndexPrototypesIn(string file)
+ private static IEnumerable<(string type, string id)> IndexPrototypesIn(string file, bool ignored = false)
{
var stream = new YamlStream();
@@ -223,7 +222,7 @@ public static partial class GameDataScrounger
var id = entryMapping[IdNode];
var type = entryMapping[TypeNode];
- var @abstract = false;
+ var @abstract = ignored;
if (entryMapping.TryGetNode("abstract", out YamlScalarNode? abstractNode))
{
// TODO: This technically will exclude prototypes that use the abstract field for their own stuff,