Fragile: relying on certain behavior between action and response, and using this to know when to validate the response
Better: make no assumptions about the behavior. Instead, continuously check for a valid response for a reasonable amount of time.
e.g.:
Fragile:
- perform action
- wait for loading ui (if the devs change or remove loading ui, this will break)
- validate response
Better:
- perform action
- check for valid response
- wait a second or two
- check again...for 5-10 seconds
The second is only invalidated if the response changes (less likely). The former is invalidated if the loading UI changes (apparently, any time the PM/devs get bored).
Thursday, October 6, 2011
Wednesday, October 5, 2011
TimeStamp100nSec is DateTime FileTime
The TimeStamp100nSec value of CounterSamples is in the same format you get from DateTime.ToFileTime() (or maybe DateTime.ToFileTimeUtc() in some situations, not sure).
This was not made clear to me in any documentation I could find, but some example code half-way down this page spells it out.
To go from TimeStamp100nSec to a DateTime object, use DateTime.FromFileTime(timestamp100nsec).
This was not made clear to me in any documentation I could find, but some example code half-way down this page spells it out.
To go from TimeStamp100nSec to a DateTime object, use DateTime.FromFileTime(timestamp100nsec).
Subscribe to:
Posts (Atom)