Skip to main content
Participating Frequently
January 20, 2010
Question

Async Theories

  • January 20, 2010
  • 1 reply
  • 742 views

I have a test case where I've got a theory with some data points, but the thing I need to test is a component.

When I change [Theory] to [Theory(async)] and add an asyncHandler in the method, I get an error stating:

"Cannot add asynchronous functionality to methods defined by Test,Before or After that are not marked async"

I guess async theories are not possible currently? Are there some simple changes I can make to some source to get this working quickly?

This topic has been closed for replies.

1 reply

Ir0nCladAuthor
Participating Frequently
January 20, 2010

I could do a [Before] and [After] method to setup the component and tear it down, but if I need to feed it data that updates properties in the commitProperties method, then I would still need the ability to have async theories.

I guess I could always force a validate now on the component after calling initialize, but that seems kinda lame.

Participating Frequently
January 22, 2010

Yes, this is on the list for the (nearer) future releases, we just had to bias the time we had toward bugs over features for the moment. I think there is already a Jira issue on this, but, if not, add one so we can all track against it.

Mike

Participant
January 27, 2010

Done.

https://bugs.adobe.com/jira/browse/FXU-102