Parametrization being a bit too broad

Aaron Bentley aaron at aaronbentley.com
Thu May 19 23:11:12 UTC 2011


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 11-05-18 06:39 AM, John Arbash Meinel wrote:
> So one idea was for tests do define the actual function that they are
> testing. (Such as Repository.apply_inventory_delta). And then the
> parametrizer would create the full width of tests, but can keep track of
> a set of functions it has tested. Like:
> 
>  if func in self._tested_funcs:
>   self._tested_funcs.add(func)
>   run_test()
>  else:
>   # this version of the test has already been run.
>   pass

It seems nice, but I think it could easily miss cases where func
delegated responsibility to private methods that were overridden, and so
behaved very differently.

One solution would be to test the private methods, but some subclasses
could override func, rather than providing the private methods.  It just
seems hard to get right on an automatic basis.

Aaron
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk3Vo5AACgkQ0F+nu1YWqI1m4QCdGZH14QZFDYieGq2DxCEnvwIm
54kAn3RnjIP5j8r4Ch15V8vycJV8xxSQ
=0Cka
-----END PGP SIGNATURE-----



More information about the bazaar mailing list