More fun with CUIT 03 August 2012 Donovan-Brown Work (0) Problem: I have a CUIT that does not run as fast as I would like. Solution: Use the Coded UI Test Editor in Feature Pack 2 to adjust the actions recorded. Explanation:
What to do when my CUIT thows a PlaybackFailureException 09 October 2011 Donovan-Brown Work (0) Updated (Oct 11, 2011) Problem: I have a textbox that has a maximum length of five characters. I want to record a Data Driven CUIT to test that you cannot type in more than five characters. However, when I attempt to set the textbox to a six character value the CUIT throws a PlaybackFailureException. Solution: Simply set Playback.PlaybackSettings.SkipSetPropertyVerification = true; before the call that throws the PlaybackFailureException and return it to false after. Explanation: After setting a property of any UI control, the record and playback engine performs a verification step to make sure that the set succeeded and the UI control now has the value it attempted to set it to. For example if you have a text box that only allows 5 characters and you attempt to set it to 6 characters the engine will throw a PlaybackFailureException. If you are trying to test that if I actually type 123456 that the value is 12345 you will have to set Playback.PlaybackSettings.SkipSetPropertyVerification = true; before your test attempts to fill in the value.
Demo Source Code 11 February 2010 Donovan-Brown Work (0) For those that wanted the demo code I presented today in the Web Cast it is here. It includes the code to databind a Coded UI Test. Thanks for joining me and I hope you enjoyed it. Demo.zip (408.41 kb)