diff --git a/pwiz_tools/Skyline/TestTutorial/Ms1FullScanFilteringTutorial.cs b/pwiz_tools/Skyline/TestTutorial/Ms1FullScanFilteringTutorial.cs index 0d6380a033..c10890178d 100644 --- a/pwiz_tools/Skyline/TestTutorial/Ms1FullScanFilteringTutorial.cs +++ b/pwiz_tools/Skyline/TestTutorial/Ms1FullScanFilteringTutorial.cs @@ -567,9 +567,9 @@ protected override void DoTest() RevertDoc(undoIndex); // undo changes ActivateReplicate(TIP_NAME); - ClickChromatogram(TIP_NAME, 37.32, 151, checkTitle: true); + ClickChromatogram(TIP_NAME, 37.35, 151, titleTime: 37.32); // Click to the right of the point, or it will often end up 37.14 PauseForFullScanGraphScreenShot("MS1 spectrum graph 37.32 minutes", tutorialPage++); - ClickChromatogram(TIP_NAME, 33.19, 328.1, checkTitle: true); + ClickChromatogram(TIP_NAME, 33.19, 328.1, titleTime: 33.19); PauseForFullScanGraphScreenShot("MS1 spectrum graph 33.19 minutes", tutorialPage++); if (PreferWiff) diff --git a/pwiz_tools/Skyline/TestTutorial/SmallMolMethodDevCEOptTutorial.cs b/pwiz_tools/Skyline/TestTutorial/SmallMolMethodDevCEOptTutorial.cs index 97c8152b49..088e69edd9 100644 --- a/pwiz_tools/Skyline/TestTutorial/SmallMolMethodDevCEOptTutorial.cs +++ b/pwiz_tools/Skyline/TestTutorial/SmallMolMethodDevCEOptTutorial.cs @@ -20,6 +20,7 @@ using System; using System.Collections.Generic; using System.Drawing; +using System.Globalization; using System.IO; using System.Linq; using Microsoft.VisualStudio.TestTools.UnitTesting; @@ -89,15 +90,19 @@ protected override void DoTest() SetCsvFileClipboardText(GetTestPath("Energy_TransitionList.csv")); var confirmHeadersDlg = ShowDialog(SkylineWindow.Paste); - RunUIForScreenShot(() => ResizeFormOnScreen(confirmHeadersDlg, 1070, null)); - PauseForScreenShot("Confirming column headers", 5); + // TODO: After translation is updated this first image will need to be added for Chinese and Japanese + if (Equals("en", CultureInfo.CurrentCulture.TwoLetterISOLanguageName)) + { + RunUIForScreenShot(() => ResizeFormOnScreen(confirmHeadersDlg, 1070, null)); + PauseForScreenShot("Confirming column headers", 5); + } OkDialog(confirmHeadersDlg, confirmHeadersDlg.OkDialog); RunUI(() => { AdjustSequenceTreePanelWidth(); }); - + FocusDocument(); PauseForScreenShot("Main window after paste from csv", 5); var docTargets = WaitForDocumentChange(doc); @@ -343,6 +348,7 @@ protected override void DoTest() molNode.Nodes[1].Expand(); SkylineWindow.ArrangeGraphsTabbed(); }); + FocusDocument(); PauseForScreenShot("Skyline window with calibration data", 23); // Linearity @@ -455,7 +461,7 @@ protected override void DoTest() PauseForScreenShot("Import Results Files form", 31); OkDialog(openDataSourceDialog1, openDataSourceDialog1.Open); } - + FocusDocument(); PauseForScreenShot("Skyline shows new replicate \"CE Optimization\"", 32); RunUI(() => { @@ -466,6 +472,8 @@ protected override void DoTest() SkylineWindow.ShowSingleTransition(); SkylineWindow.ShowSplitChromatogramGraph(true); }); + RestoreViewOnScreen(33); + FocusDocument(); PauseForScreenShot("Split graph", 33); RunUI(() => diff --git a/pwiz_tools/Skyline/TestTutorial/SmallMolMethodDevCEOptViews.data/cover.view b/pwiz_tools/Skyline/TestTutorial/SmallMolMethodDevCEOptViews.data/cover.view new file mode 100644 index 0000000000..73f35457af --- /dev/null +++ b/pwiz_tools/Skyline/TestTutorial/SmallMolMethodDevCEOptViews.data/cover.view @@ -0,0 +1,89 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/pwiz_tools/Skyline/TestTutorial/SmallMolMethodDevCEOptViews.data/p16.view b/pwiz_tools/Skyline/TestTutorial/SmallMolMethodDevCEOptViews.data/p16.view new file mode 100644 index 0000000000..6536bd84c4 --- /dev/null +++ b/pwiz_tools/Skyline/TestTutorial/SmallMolMethodDevCEOptViews.data/p16.view @@ -0,0 +1,86 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/pwiz_tools/Skyline/TestTutorial/SmallMolMethodDevCEOptViews.data/p33.view b/pwiz_tools/Skyline/TestTutorial/SmallMolMethodDevCEOptViews.data/p33.view new file mode 100644 index 0000000000..20d74829ae --- /dev/null +++ b/pwiz_tools/Skyline/TestTutorial/SmallMolMethodDevCEOptViews.data/p33.view @@ -0,0 +1,87 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/pwiz_tools/Skyline/TestTutorial/SmallMolMethodDevCEOptViews.zip b/pwiz_tools/Skyline/TestTutorial/SmallMolMethodDevCEOptViews.zip deleted file mode 100644 index 5f5fe6d04a..0000000000 Binary files a/pwiz_tools/Skyline/TestTutorial/SmallMolMethodDevCEOptViews.zip and /dev/null differ diff --git a/pwiz_tools/Skyline/TestTutorial/SmallMoleculesQuantificationTutorial.cs b/pwiz_tools/Skyline/TestTutorial/SmallMoleculesQuantificationTutorial.cs index 44d40b4774..b92a7d5d0b 100644 --- a/pwiz_tools/Skyline/TestTutorial/SmallMoleculesQuantificationTutorial.cs +++ b/pwiz_tools/Skyline/TestTutorial/SmallMoleculesQuantificationTutorial.cs @@ -134,6 +134,7 @@ protected override void DoTest() SelectNode(SrmDocument.Level.Transitions, 0); SelectNode(SrmDocument.Level.Transitions, 1); SelectNode(SrmDocument.Level.Molecules, 0); + FocusDocument(); PauseForScreenShot("Skyline with small molecule targets", 7); var transitionSettingsUI = ShowDialog(SkylineWindow.ShowTransitionSettingsUI); @@ -189,7 +190,7 @@ protected override void DoTest() SelectNode(SrmDocument.Level.Transitions, 1); SelectNode(SrmDocument.Level.Molecules, 0); - + FocusDocument(); PauseForScreenShot("Skyline window multi-precursor graph", 13); var docResults = SkylineWindow.Document; @@ -227,6 +228,12 @@ protected override void DoTest() SelectNode(SrmDocument.Level.Transitions, 0); SelectNode(SrmDocument.Level.Transitions, 1); SelectNode(SrmDocument.Level.Molecules, 0); + // TODO: Removed this once Nick has fixed what is causing x-axis labels in the Peak Areas plot to end up horizontal + RunUIForScreenShot(() => SkylineWindow.Height += 200); + JiggleSelection(); + RunUIForScreenShot(() => SkylineWindow.Height -= 200); + JiggleSelection(); + FocusDocument(); PauseForScreenShot("Skyline window multi-replicate layout", 14); // Peak integration correction @@ -354,7 +361,7 @@ protected override void DoTest() } RunUI(() => SkylineWindow.ShowCalibrationForm()); - PauseForScreenShot("Calibration Curve ", 23); + PauseForGraphScreenShot("Calibration Curve ", 23); EnableDocumentGridColumns(documentGrid, Resources.SkylineViewContext_GetDocumentGridRowSources_Replicates, 47, new[] @@ -413,7 +420,7 @@ protected override void DoTest() var calibrationForm = FindOpenForm(); RunUI(() => calibrationForm.UpdateUI(false)); - PauseForScreenShot("Calibration Curve: Log", 26); + PauseForGraphScreenShot("Calibration Curve: Log", 26); } } diff --git a/pwiz_tools/Skyline/TestTutorial/SmallMoleculesTutorial.cs b/pwiz_tools/Skyline/TestTutorial/SmallMoleculesTutorial.cs index dc2c8f81ce..696567900b 100644 --- a/pwiz_tools/Skyline/TestTutorial/SmallMoleculesTutorial.cs +++ b/pwiz_tools/Skyline/TestTutorial/SmallMoleculesTutorial.cs @@ -93,10 +93,7 @@ protected override void DoTest() { // Setting the UI mode, p 2 var startPage = WaitForOpenForm(); - RunUI(() => startPage.SetUIMode(SrmDocument.DOCUMENT_TYPE.proteomic)); -// PauseForScreenShot("Start Window proteomic", 2); RunUI(() => startPage.SetUIMode(SrmDocument.DOCUMENT_TYPE.small_molecules)); -// PauseForScreenShot("Start Window small molecule", 3); ShowSkyline(() => startPage.DoAction(skylineWindow => true)); } @@ -125,12 +122,8 @@ protected override void DoTest() } }); PauseForScreenShot("Column Select Dlg with column headers selected", 6); - OkDialog(col4Dlg, col4Dlg.OkDialog); - - - var docTargets = WaitForDocumentChange(doc); AssertEx.IsDocumentState(docTargets, null, 6, 12, 19, 21); @@ -164,7 +157,7 @@ protected override void DoTest() } SelectNode(SrmDocument.Level.MoleculeGroups, 0); - + FocusDocument(); PauseForScreenShot("Skyline window multi-target graph", 9); var docResults = SkylineWindow.Document; diff --git a/pwiz_tools/Skyline/TestUtil/AbstractFunctionalTestEx.cs b/pwiz_tools/Skyline/TestUtil/AbstractFunctionalTestEx.cs index c6f4669ce1..9382eaabab 100644 --- a/pwiz_tools/Skyline/TestUtil/AbstractFunctionalTestEx.cs +++ b/pwiz_tools/Skyline/TestUtil/AbstractFunctionalTestEx.cs @@ -526,14 +526,14 @@ public static void ClickChromatogram(double x, double y, PaneKey? paneKey = null ClickChromatogram(null, x, y, paneKey); } - public static void ClickChromatogram(string graphName, double x, double y, PaneKey? paneKey = null, bool checkTitle = false) + public static void ClickChromatogram(string graphName, double x, double y, PaneKey? paneKey = null, double? titleTime = null) { WaitForGraphs(); var graphChromatogram = GetGraphChrom(graphName); MouseOverChromatogramInternal(graphChromatogram, x, y, paneKey); RunUI(() => graphChromatogram.TestMouseDown(x, y, paneKey)); WaitForGraphs(); - CheckFullScanSelection(graphName, x, y, paneKey, checkTitle); + CheckFullScanSelection(graphName, x, y, paneKey, titleTime); } public static void MouseOverChromatogram(double x, double y, PaneKey? paneKey = null) @@ -568,21 +568,21 @@ private static void MouseOverChromatogramInternal(GraphChromatogram graphChromat sleepInterval * sleepCycles / 1000.0))); } - public static void CheckFullScanSelection(double x, double y, PaneKey? paneKey = null, bool checkTitle = false) + public static void CheckFullScanSelection(double x, double y, PaneKey? paneKey = null, double? titleTime = null) { - CheckFullScanSelection(null, x, y, paneKey, checkTitle); + CheckFullScanSelection(null, x, y, paneKey, titleTime); } - public static void CheckFullScanSelection(string graphName, double x, double y, PaneKey? paneKey = null, bool checkTitle = false) + public static void CheckFullScanSelection(string graphName, double x, double y, PaneKey? paneKey = null, double? titleTime = null) { var graphChromatogram = GetGraphChrom(graphName); WaitForConditionUI(() => SkylineWindow.GraphFullScan != null && SkylineWindow.GraphFullScan.IsLoaded); - if (checkTitle) + if (titleTime.HasValue) { // Good idea to check the title for a tutorial screenshot - var matchTime = Regex.Match(SkylineWindow.GraphFullScan.TitleText, @".([0-9.]+) [\w]+.$"); + var matchTime = Regex.Match(SkylineWindow.GraphFullScan.TitleText, @".([0-9.,]+) [\w]+.$"); Assert.IsTrue(matchTime.Success); - Assert.AreEqual(x, double.Parse(matchTime.Groups[1].Value)); + Assert.AreEqual(titleTime.Value, double.Parse(matchTime.Groups[1].Value)); } Assert.AreEqual(string.Empty, graphChromatogram.TestFullScanSelection(x, y, paneKey)); }