Timeline for Is there a good standard approach for execution of a long list of methods/functions?
Current License: CC BY-SA 3.0
10 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Jan 31, 2017 at 22:22 | comment | added | Gaz83 | TaskFunction returned bool so it was something like TaskFunction = () => { return Method1(someIntProperty, someIntProperty2); }. | |
| Jan 31, 2017 at 21:50 | comment | added | Mike Nakis | There is no easy answer to that. But how did you work with TaskItems in the TestTaskItems collection? You appear to have had a TaskFunction.Invoke(); method, which obviously takes no arguments, so you appear to have already resolved this issue somehow. | |
| Jan 31, 2017 at 19:58 | comment | added | Gaz83 | @MikeNakis Just looking further into your idea of building the collection using reflectiong. How do you handle functions that require different parameters? Example, I have Method 1 that require 2 int parameters and Method 2 requires a string and a bool. How do use reflection and then supply the parameters that is required? If it helps, the class that has the BuildTestSequence has the relevant properties that are passed onto these methods as parameters. | |
| Jan 31, 2017 at 17:59 | vote | accept | Gaz83 | ||
| Jan 30, 2017 at 16:58 | vote | accept | Gaz83 | ||
| Jan 31, 2017 at 17:59 | |||||
| Jan 29, 2017 at 18:23 | comment | added | Doc Brown | Good answer, found this example for the reflection approach: stackoverflow.com/questions/12323633/… | |
| Jan 29, 2017 at 17:57 | comment | added | Mike Nakis | Glad to be of help. I noticed you have asked questions in the past which have received decent answers but you have not accepted any of them, so I cannot help but remark that the convention here is to "accept" the answer that best suits your needs. (Not immediately, but after a couple of days have passed.) | |
| Jan 29, 2017 at 17:14 | comment | added | Gaz83 | Thanks for that. You have given me something to think about :-) | |
| Jan 29, 2017 at 16:54 | comment | added | MetaFight | Similarly, I was going to suggest using MEF to resolve tests at runtime. | |
| Jan 29, 2017 at 16:46 | history | answered | Mike Nakis | CC BY-SA 3.0 |