Merge pull request #2939 from larsbrubaker/design_tools

Fixing tests
This commit is contained in:
Lars Brubaker 2018-01-24 16:46:02 -08:00 committed by GitHub
commit 5860bfe4a0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 10 additions and 8 deletions

View file

@ -63,6 +63,7 @@ namespace MatterHackers.MatterControl.PartPreviewWindow
{
Padding = 10,
};
column.AddChild(new TextWidget("Options".Localize())
{
HAnchor = HAnchor.Left
@ -111,6 +112,7 @@ namespace MatterHackers.MatterControl.PartPreviewWindow
var sectionWidget = new SectionWidget("Advanced", subPanel, theme, expanded: anySettingOverridden)
{
Name = "Advanced Section",
HAnchor = HAnchor.Stretch,
VAnchor = VAnchor.Fit,
Margin = 0

@ -1 +1 @@
Subproject commit 9d5af195e1e98f14f0f63f9b3b0949c19417e506
Subproject commit ccc0ce556c6b08e1de3d3bbad16e2e8b9d05173e

@ -1 +1 @@
Subproject commit c5ae31ce23f1f0fa1efde99102da2a80b7a4cefa
Subproject commit b1a1664c7a1c8593345cb5e2690998ad2a34eb66

View file

@ -146,17 +146,12 @@ namespace MatterHackers.MatterControl.Tests.Automation
testRunner.ClickByName("Features Tab");
// Find any sibling toggle switch and scroll the parent to the bottom
var widget = testRunner.GetWidgetByName("has_fan Row", out _);
var scrollable = widget.Parents<ScrollableWidget>().First();
scrollable.ScrollPosition = new Vector2(0, -100);
CheckAndUncheckSetting(testRunner, SettingsKey.heat_extruder_before_homing, false);
CheckAndUncheckSetting(testRunner, SettingsKey.has_fan, true);
return Task.CompletedTask;
}, overrideWidth: 1224, overrideHeight: 900);
}, overrideWidth: 1224, overrideHeight: 900, maxTimeToRun: 600);
}
[Test]
@ -372,6 +367,8 @@ namespace MatterHackers.MatterControl.Tests.Automation
Assert.IsTrue(ActiveSliceSettings.Instance.GetValue<bool>(settingToChange) != valueToSet);
testRunner.ScrollIntoView(checkBoxName);
testRunner.ClickByName(checkBoxName);
// give some time for the ui to update if necessary
testRunner.Delay(2);

View file

@ -688,6 +688,8 @@ namespace MatterHackers.MatterControl.Tests.Automation
testRunner.WaitFor(() => printerPopup.Enabled);
testRunner.ClickByName("PrintPopupMenu");
testRunner.ClickByName("Advanced Section");
}
/// <summary>
@ -697,6 +699,7 @@ namespace MatterHackers.MatterControl.Tests.Automation
public static void StartPrint(this AutomationRunner testRunner)
{
testRunner.OpenPrintPopupMenu();
testRunner.ScrollIntoView("Start Print Button");
testRunner.ClickByName("Start Print Button");
}