A simpler test framework?
Martin Pool
mbp at sourcefrog.net
Fri Jul 17 06:39:13 BST 2009
2009/7/17 Aaron Bentley <aaron at aaronbentley.com>:
>> I think in Shelver this should be abstracted a bit into a method
>> called on the UIFactory that asks for a multiple-choice response.
>> Then the UIFactory can arrange that when run in this context, it has
>> just
>>
>> Apply change? [yNfq] y
>>
>> I think that's clearly the most desirable thing as far as testable
>> documentation or easy approachability
>
> Sure, but it's not what you'd want if you were implementing a GUI.
> Anyone who implements those prompts with modal dialogs is evil.
Yes, it's unrealistic to suppose you can have application code make
very fine-grained requests of the UI and have that magically turn into
a proper GUI. I think in some cases, in uncommon cases, it's ok - as
a hypothetical example if we said "do you want to steal this
apparently dead lock" it would be all right. For shelve in a GUI
really you'd want something entirely different but drawing on the same
lower level code so the user can pick in arbitrary order.
Nevertheless having an abstraction around modal guis is still a bit
useful so that we can do things like this in testing.
--
Martin <http://launchpad.net/~mbp/>
More information about the bazaar
mailing list