[PATCH] samba-tool throws error if there is an empty FSMO role

Andrew Bartlett abartlet at samba.org
Mon May 9 23:02:47 UTC 2016


On Mon, 2016-05-09 at 19:04 +0100, Rowland Penny wrote:
> 
> OK, I have tried, but I just don't understand how the tests are
> supposed 
> to work, it looks like 'selftest.pl' calls various other scripts and 
> runs a test script that ultimately tests something (in my case, 
> fsmo.py). writing a script to actually run 'samba-tool fsmo show'
> should 
> be fairly easy, but the bits in-between are defeating me. it doesn't 
> help that whilst looking in the various 'selftest' directories, I am 
> finding perl, python and bash scripts. I can understand the last
> two, 
> but perl, well this is a foreign language to me and I don't speak
> any 
> foreign languages :-)

Just copy the references to timecmd, and copy timecmd.py.  It is a
noble cause to understand the whole stack, but you don't need to.  Just
copy the example given, adjust as required and run as 'make test
TESTS=fsmo'.  

Once you have that much done, we can review and help you with any
details that you missed but need to know, rather than trying to explain
the whole selftest system, which sadly has grown to a level of
complexity beyond most of us.

> Is there an idiots guide to writing Samba tests ??? The idiot being
> me :-D

Andreas did a presentation about this at last SambaXP.

Andrew Bartlett

-- 
Andrew Bartlett
https://samba.org/~abartlet/
Authentication Developer, Samba Team         https://samba.org
Samba Development and Support, Catalyst IT   
https://catalyst.net.nz/services/samba









More information about the samba-technical mailing list