[Gambas-user] Using test interface for scripter testing

Brian G brian at westwoodsvcs.com
Mon Jul 6 21:39:21 CEST 2020


Will give it a try!
--
Thanks
Brian Sunday, 05 July 2020, 11:45PM -07:00 from Christof Thalhofer  chrisml at deganius.de :

>Hello Brian,
>
>Am 30.06.20 um 01:38 schrieb Brian G:
>
> Assert.Exported("namelist",......... ) ' list of expected exported
> modules and classes fails if don't match 
>
> Assert.Interface("modOrClass", "interfaceFuncOrVarsOrProperty".....)
> ' test exported mods or classes that the interface is correct ie
> public functions and variables exposed, returns
>
>I find these things useful. If you are interested in enhancing gb.test
>then it should be done like this:
>
>To ensure it's stability gb.test tests itself so at first you should
>write tests for gb.test that require the new methods:
>
>Assert.Interface("ExistingClass", "ExistingSymbol")
>
>There should also be tests that test the right behavior on failure, like
>this:
>
>Test.IntendedFailure
>Assert.Interface("NotExistingClass", "AnySymbol")
>
>Test.IntendedFailure
>Assert.Interface("ExistingClass", "NotExportedSymbol")
>
>These tests must be part of the testsuite "All good" in gb.test.
>
>After that write the methods in 'Assert' that meet the requirements,
>they should be well documented.
>
>--------------------------------------------------------------------
>
>To bring your work into Gambas you must fork Gambas on Gitlab, commit
>your changes and then create a merge request.
>
>Alles Gute
>
>Christof Thalhofer
>
>-- 
>Dies ist keine Signatur
>
>
>----[  http://gambaswiki.org/wiki/doc/netiquette ]----
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gambas-basic.org/pipermail/user/attachments/20200706/a8c38d1a/attachment.html>


More information about the User mailing list