[Piglit] [PATCH 04/15] arb_direct_state_access: Testing NamedBufferData.
Martin Peres
martin.peres at linux.intel.com
Wed Feb 18 06:59:07 PST 2015
On 23/01/15 21:03, Laura Ekstrand wrote:
> ---
> tests/spec/arb_direct_state_access/namedbufferstorage.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/tests/spec/arb_direct_state_access/namedbufferstorage.c b/tests/spec/arb_direct_state_access/namedbufferstorage.c
> index 2ddfab6..6630467 100644
> --- a/tests/spec/arb_direct_state_access/namedbufferstorage.c
> +++ b/tests/spec/arb_direct_state_access/namedbufferstorage.c
> @@ -217,8 +217,8 @@ read_subtest(GLboolean coherent, GLboolean client_storage)
>
> glClear(GL_COLOR_BUFFER_BIT);
> glCreateBuffers(1, &srcbuf);
> + glNamedBufferData(srcbuf, BUF_SIZE, array, GL_STATIC_DRAW);
> glBindBuffer(GL_COPY_READ_BUFFER, srcbuf);
> - glBufferData(GL_COPY_READ_BUFFER, BUF_SIZE, array, GL_STATIC_DRAW);
>
> /* Copy some data to the mapped buffer and check if the CPU can see it. */
> glBindBuffer(GL_COPY_WRITE_BUFFER, buffer);
This is a good functional test but you do not test for conformance with the spec. It also
misses entirely all the other usage which could be ill-implemented. I understand that you
may be implementing those tests with the assumption that the previous function worked
properly and you only test the differences you introduced in mesa but is this really how
we are supposed to write the tests?
I really don't know, hence why I am asking.
More information about the Piglit
mailing list