public void OpenLocalImage_OpenDialogCorrectly() { OpenFileDialog dialog = new OpenFileDialog(); OpenImageService service = new OpenImageService(); service.OpenLocalImage(dialog); if (dialog.ShowDialog() == DialogResult.OK) { Assert.Pass(); } }
public static void OpenLocalImage(OpenFileDialog OBrwsDialog, OpenImageService service) { service.OpenLocalImage(OBrwsDialog); if (OBrwsDialog.ShowDialog() == DialogResult.OK) { path = OBrwsDialog.FileName; } else { path = null; } }
public static void OpenWebImage(OpenFromWebMenu menu, OpenImageService service) { service.OpenWebImage(menu); path = $"{Path.GetTempPath()}desktop{SelectMenu.count}.png"; }