Hi doru and others
so finally what is the conventions we should use for example? exampleFooBar <example> Stef |
I am not a fan of pragmas myself, but then I am also not an enemy. Personal I would prefer if we would follow a similar approach to unit testing, meaning separate classes for examples. I dont like the idea of mixing regular code with examples even just for a single example. Separate class will also mean there would be no need for the name of the method to contain "example". So you can both name your example whatever you want and keep your code separate , clean and nice. On Mon, Oct 27, 2014 at 2:15 PM, stepharo <[hidden email]> wrote: Hi doru and others |
> So you can both name your example whatever you want and keep your code separate , clean and nice. I believe the reason for convention was clickable examples in system browser. So as far as tests go even if they are in separate classes you can only run methods beginning with 'test' and not other support (setUp/..) methods. The same would go for examples. You may need other non-example methods to run the example so you need to discriminate them. Also shouldn't this convention for pragmas vs method names be more global? For example ComposableModel class>>defaultSpec vs <spec> and so on. Peter On Mon, Oct 27, 2014 at 1:33 PM, kilon alios <[hidden email]> wrote:
|
I agree with kilon. Sorry if it is an stupid question but why not identify them by grouping into "examples" protocols? The rule could be matching "examples*" named protocols, then you can group examples that match different features ("examples-featureA", "examples-featureB" ...). On 27 October 2014 13:56, Peter Uhnák <[hidden email]> wrote:
|
In reply to this post by stepharo
Hi Stef, I renamed the pragmas that we used in the inspector to <example> and <example: 'Title'> (the method can have any name) It will be integrated with the next GTools version and then we can iterate (keep the pragmas, move examples to other classes, etc) Cheers, Andrei On Mon, Oct 27, 2014 at 9:15 AM, stepharo <[hidden email]> wrote: Hi doru and others |
Hi, We should support: <example: 'Title'> <example> (in this case, the name is by default derived from the method selector) Cheers, Doru On Mon, Oct 27, 2014 at 2:16 PM, Andrei Chis <[hidden email]> wrote:
"Every thing has its own flow"
|
Free forum by Nabble | Edit this page |