Right, makes sense. I will resend this patch with the changes today. Fwiw, I've intentionally not added tests in patch 4/4 to validate the image struct in InitFromImage right now. I will include them in the implementation patch for this function. I'll be using a helper function which would validate the struct and return a BOOL, which would be re-used for CreateTexture as well.
Cheers, Aaryaman
On Mon, Apr 25, 2016 at 3:21 AM, Stefan Dösinger stefandoesinger@gmail.com wrote:
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256
Am 2016-04-24 um 21:49 schrieb Aaryaman Vasishta:
My bad, that was a copy mistake. Will resend patch.
Even better than not checking would be to fill the array with some dummy value and checking that the content wasn't touched.
I also recommend to re-order the tests so that failing tests are grouped together. That way you don't have to re-fill the array with a dummy value after a succeeding test.
(try 2 sending this. Forgive me if it arrives twice)
-----BEGIN PGP SIGNATURE----- Version: GnuPG v2
iQIcBAEBCAAGBQJXHT/uAAoJEN0/YqbEcdMwaXkP/iKRAq8nY5GxoETGm9pUZPML xFzwsmiRGidQv+TpXX3e5jAvgljxZMAVdlapZwQlvzdlZQxkjS5DcbcSAwrRDxHB QeRPaneMttPqYEQ7YCqpRt77/UNHtgTxjxF3RXMn1TIutnsTMiO6s4weyb0BbSdP PTdqyAnV9XFqmUZDVcHq/4pvoX/XEnrk5zxkv6+kJo5vqAYLMjRrB4Lu+g8oqgPE 1polBPIcRluYX+VWFNHWVSwmBOlO6MMDa4JLj5WbN/m0i/XQOYD5JjcXeF5cxBwd jZ+8d2wvta8Sgl1oDKAGw+saHEKFBth9+zVa9AfcDUrNgsrq52DYneAXrGnsjfk3 llL7Twz71eLtMo4YgRqLXLYxA5KCJSVvpwn8EaKBoCrUmv/pP/0j0MIZvMGXiQQG /acO/bC2EsgkLW69Tj4D4fymeJNJlk5sZf7QbeNCh61JPRlSZblsSJVt4DkiBG/l 7CKZXqtHOZhfqa1MUGXxEajyv25KoUIcinPtKTFGAv2CLk1dm3hj3FteRJJ7M6Ag FTKN7k+67wJZUIrHLXYBWn1xjTmoYnbL5FHrDlGsEkTt655hEyhgzoL/e4XVnWdl Hh9F9ntrGN487AX6bD5zNMf0oBizVhDPyXzFHXIc/+pl3PYceexhXN0REJ61NAmJ qPqkXyPFigb34w/IzuVU =n5WM -----END PGP SIGNATURE-----