Add test workaround for inconsistent extension handling

- Allow for either naming convention
- Issue MatterHackers/MCCentral#4470
Test fails to add items to print queue
This commit is contained in:
John Lewin 2018-11-02 09:00:25 -07:00
parent 0758361f0f
commit 96831c8424

View file

@ -1033,7 +1033,13 @@ namespace MatterHackers.MatterControl.Tests.Automation
foreach (string assetName in assetNames)
{
string friendlyName = Path.GetFileNameWithoutExtension(assetName);
Assert.IsTrue(testRunner.WaitForName($"Row Item {friendlyName}"), $"{friendlyName} part should exist after adding");
string fileName = Path.GetFileName(assetName);
// Look for either expected format (print queue differs from libraries)
Assert.IsTrue(
testRunner.WaitForName($"Row Item {friendlyName}", 2)
|| testRunner.WaitForName($"Row Item {fileName}", 2),
$"{friendlyName} part should exist after adding");
}
}