Advertisement
Guest User

Untitled

a guest
Nov 1st, 2014
131
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.51 KB | None | 0 0
  1. [TestMethod]
  2. public void TestVoid()
  3. {
  4. }
  5.  
  6. [TestInitialize]
  7. public void MyTestInitialize()
  8. {
  9. Process[] processes = Process.GetProcessesByName("Notepad");
  10. if (processes.Length > 0)
  11. {
  12. _app = ApplicationUnderTest.FromProcess(processes[0]);
  13. }
  14. else
  15. {
  16. _app = ApplicationUnderTest.Launch(@"C:WindowsSystem32notepad.exe");
  17. _app.CloseOnPlaybackCleanup = false;
  18. }
  19. }
  20.  
  21. [TestCleanup]
  22. public void MyTestCleanup()
  23. {
  24. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement