[Scons-dev] tools and testing

Russel Winder russel at winder.org.uk
Wed Apr 19 01:18:18 EDT 2017


On Tue, 2017-04-18 at 20:48 -0700, Bill Deegan wrote:
> Would it be possible to mock the dub tool for a unit test?
> (Or even for a E2E test?)

I had sort of arrived at having to do that anyway to avoid the need for
the dub program on the test server. I think we have to assume the Dub
tool always does exactly what is says it does and so ignore it for all
the tests. If I extract the subprocess call into a separate Python
function, that enables mocking. For testing the basic stuff this should
be OK. I have created a special case of the unit-threaded package
because it needs a special builder for writing suite files. Most of
that is already amenable to unit test, but not end-to-end unless dub is
available.

I will set about putting these tests in place, but given the SCons test
infrastructure a full end-to-end system test may have to be left to
what happens in the field. 

-- 
Russel.
=============================================================================
Dr Russel Winder      t: +44 20 7585 2200   voip: sip:russel.winder at ekiga.net
41 Buckmaster Road    m: +44 7770 465 077   xmpp: russel at winder.org.uk
London SW11 1EN, UK   w: www.russel.org.uk  skype: russel_winder
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: This is a digitally signed message part
URL: <https://pairlist2.pair.net/pipermail/scons-dev/attachments/20170419/55e1a932/attachment.pgp>


More information about the Scons-dev mailing list