Re: [PATCH 3/4] d3drm/tests: Split tests seperately for IDirect3DRM{1-3} interfaces
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Am 2015-04-01 um 18:15 schrieb Aaryaman Vasishta:
+++ b/dlls/d3drm/tests/d3drm.c @@ -1841,6 +1841,104 @@ static void test_d3drm_qi(void) IDirect3DRM_Release(d3drm); }
+static void test_frame_qi(void) +{ There's no need to add this to d3drm.c and d3drm3.c. The versions in d3drm1.c, d3drm2.c and d3drm3.c are enough. Ideally d3drm.c will go away at some point.
+ hr = Direct3DRMCreate(&d3drm); + ok(hr == D3DRM_OK, "Cannot get IDirect3DRM interface (hr = %x)\n", hr); + + test_qi("d3drm_qi", (IUnknown *)d3drm, &IID_IDirect3DRM, tests, sizeof(tests) / sizeof(*tests)); + + IDirect3DRM_Release(d3drm); This test is version independent because there is only one way to create the d3drm object. You can just keep it in d3drm.c for now, or move it to d3drm1.c in a separate patch if you want.
--- a/dlls/d3drm/tests/Makefile.in +++ b/dlls/d3drm/tests/Makefile.in @@ -2,4 +2,7 @@ TESTDLL = d3drm.dll IMPORTS = d3drm dxguid ddraw user32 uuid C_SRCS = \ d3drm.c \ + d3drm1.c \ + d3drm2.c \ + d3drm3.c \ vector.c This doesn't match the Makefile.in file I have. You have a reordered IMPORTS line. This is why the testbot failed. Do you have other patches in your tree?
+* Copyright 2012 Andr� Hentschel This shows up wrong in my mail client. It may be a setup issue on my side. It shows up OK on http://source.winehq.org/patches/data/110484 when viewed with the browser, but if I download the patch with wget it is broken as well. Please make sure your text editor is configured to save the files as UTF8. -----BEGIN PGP SIGNATURE----- Version: GnuPG v2
iQIcBAEBAgAGBQJVHCwnAAoJEN0/YqbEcdMwqsMP/1pigFRsvxOMAYpIHbPoQzda rnKNX4egG04IFvrlObvEVNm6GUW02hgm7SB5+UcdCkXclbGbDjxW0R8M4RqoYOHs swdSxFIZX9s/wPqHJOv33oK8TDPKYUX2SwXyhyOEN7rh3LKJF4DeYGP0uW+wSMed bCXeJ9bx3X55cAGMJhP9jVdcq8ADTh8z0sYANHLBkD80OCac+KxFMmsGrxUD2e2H l6ATINj9BKlgAYGbFnoweNkiv4+O9y6zXBgOQu8Df6Jlr+mu86Jv0zi5S7MHEj4h tWwNyNyaDjTIUlfMdF3cCrKDhLhgYuuwQqij/iAdrEcGFEFn+QKeX0THCGwLeto8 nzwmEZFKYT2keJsMoHQ5tf0U6tT0xedsOjHHTHg/cg1BBj7ogtJ0YcEaxIYtF7uP 47tkjEL9iKXaN7bfdugH1D4buvufUzlZYIvehdbyNcWs3/HYHdiBAbER1ah3yAn9 TlpYdHpZstimuDkMMMLCExW/nlnGZlxz+orF9RNMm/SowtAe1aMVGGHMS5+6ZBfb 4z85+OWG8bR9D+e7+OeOYr/3Z62wiKLppRVQiJ4NgrGgv4ex2rIjqkiKBTEgSZm7 WTptfVrMCQ8zHEpos8iZHZOcoOLVFX4ylQaNNXmssGtwcLqH/P8o7KAk3o6RO+g0 qlkMVFMPEn7fE9h8WJfj =Jeuf -----END PGP SIGNATURE-----
There's no need to add this to d3drm.c and d3drm3.c. The versions in d3drm1.c, d3drm2.c and d3drm3.c are enough. Ideally d3drm.c will go away at some point.
I was planning in removing them from the start - but I must've forgotten to remove them while sending the patch over. I'll do the same and resend the patches.
+ hr = Direct3DRMCreate(&d3drm); + ok(hr == D3DRM_OK, "Cannot get IDirect3DRM interface (hr = %x)\n", hr); + + test_qi("d3drm_qi", (IUnknown *)d3drm, &IID_IDirect3DRM, tests, sizeof(tests) / sizeof(*tests)); + + IDirect3DRM_Release(d3drm); This test is version independent because there is only one way to create the d3drm object. You can just keep it in d3drm.c for now, or move it to d3drm1.c in a separate patch if you want.
So I should remove this test from d3drm1.c, d3drm2.c and d3drm3.c aswell? I'll keep this test in d3drm.c as it is. I agree that we should keep version independent tests in d3drm.c, and the rest in their respective files.
--- a/dlls/d3drm/tests/Makefile.in +++ b/dlls/d3drm/tests/Makefile.in @@ -2,4 +2,7 @@ TESTDLL = d3drm.dll IMPORTS = d3drm dxguid ddraw user32 uuid C_SRCS = \ d3drm.c \ + d3drm1.c \ + d3drm2.c \ + d3drm3.c \ vector.c This doesn't match the Makefile.in file I have. You have a reordered IMPORTS line. This is why the testbot failed. Do you have other patches in your tree?
I might've modified them a couple weeks ago. I'll resend the patch with the proper ordered Makefile.in
+* Copyright 2012 Andr� Hentschel This shows up wrong in my mail client. It may be a setup issue on my side. It shows up OK on http://source.winehq.org/patches/data/110484 when viewed with the browser, but if I download the patch with wget it is broken as well. Please make sure your text editor is configured to save the files as UTF8.
I used visual studio to copy these lines from d3drm.c. I'll fix it accordingly and resend the patch.
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Am 2015-04-01 um 19:43 schrieb Aaryaman Vasishta:
I agree that we should keep version independent tests in d3drm.c, and the rest in their respective files. No, the idea is to have only d3drm1.c, d3drm2.c and d3drm3.c. I don't expect many version independent tests that deal with IDirect3DRM. I think this test is the only one, since everything else can be accessed through IDirect3DRM, IDirect3DRM2 and IDirect3DRM3.
There are some math and vector helper functions that are independent of the d3drm COM interfaces and are thus not versioned. They are in vector.c, and I think that's a good place for them. -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBAgAGBQJVHDPEAAoJEN0/YqbEcdMwR9wQAJBsW5LD/M8d9JYIlakkxyq6 wjbZkfhpI2Sgjj6lnUpuTmBl2pVm4kqbzu2kMdGsbV6//9+zRRF1cfN/8XE/ypgc uL/RwjdzM+hhzlq5p9KlLHg+UsMTjS3X2XrtA5h8p7T4iZ9enLFo7w9SAzM5hg6i xf+RhkkJn3rsW16H85C4QyceF7FClHWVjk7GZ7+3e/2LpgwSsheul3es+xfIGKwE m/h8Tv7YYQDncT3koRjvIBXrvTks6bcRaJA1+CArLL7xbGuBk9u0YTQXPZnAaKXu LdmMKn/QWndE4mL3+pPk1Gq1JcmaCdDudCAo02QsVBd97zCVjwNUG5joanm8T1bs lKZmehqQZYaX2YNN6u7W6XlEDAP2snrRktBkvqoqyLJlo2FPnlZElw2h3QABAWkR nEd3R3nRfEVmHXV46Un5cWAFSnN8gnQ3CXj4KQ1UWf68V7NBItUFSoEGc2Oq79B3 rvyfgz5hF5DbjrklPK7SfxYbvKbj1lbFXEoKEyBkJZdZrsH5/ASXd/D+6vg4LggQ JCIAJaA0JPh0IPTWPcxiG9GsEWBm7mC+UI6Fr3pxpVm6PitP/cb1sVh/CtSc6nYW sjZ+hmjyMgJGGfDCbuYPqDl7TrWhIeK4O1lIXsdSOfPESPQWC++POTF0os+M2MuM q4DbIpzgp8i3I1ppdUuy =6EYr -----END PGP SIGNATURE-----
On 1 April 2015 at 19:34, Stefan Dösinger <stefandoesinger(a)gmail.com> wrote:
+* Copyright 2012 Andr� Hentschel This shows up wrong in my mail client. It may be a setup issue on my side. It's not. It only looks correct on the patches site because it gets the encoding wrong, if you force it to utf-8 it's broken there as well.
participants (3)
-
Aaryaman Vasishta -
Henri Verbeet -
Stefan Dösinger