Commit Graph

11 Commits

Author SHA1 Message Date
David Neto
cac38f92dd Simplify uses of spvBinaryDestroy in tests
Always try to destroy the binary during common methods
of test fixtures.  This is safe if no other code in the test
attempted to destroy the binary.

Take advantage of the fact spvBinaryDestroy is a no-op on a nullptr,
by eliminating the null pointer check in the caller.
2015-10-26 12:54:39 -04:00
Dejan Mircevski
1a3990233c Add hex-format tests for !<integer>. 2015-10-26 12:52:01 -04:00
Dejan Mircevski
ea5a2a5242 Add invalid-operand tests for !<integer>. 2015-10-26 12:52:01 -04:00
Dejan Mircevski
a4b834e456 Make all SpirvVectors const in ImmediateInt.cpp. 2015-10-26 12:52:01 -04:00
Dejan Mircevski
d8454a7967 Tests for parsing recognizable words after !<integer>. 2015-10-26 12:52:01 -04:00
Dejan Mircevski
e75b3e769d Avoid "operands" in the !<immediate> explanation.
Also declare "!<integer> = OpCode" legal.
2015-10-26 12:52:01 -04:00
Dejan Mircevski
d5769bf08a Test consecutive opcodes being !<integer>. 2015-10-26 12:52:01 -04:00
Dejan Mircevski
741cdc4829 More !<integer> tests. 2015-10-26 12:52:01 -04:00
Dejan Mircevski
5f45e596bd Use spvOpcodeMake() in ImmediateInt tests. 2015-10-26 12:52:01 -04:00
Dejan Mircevski
0a8f219d1e Add a few unit tests for !<integer>. More to come.
Start using GMock: modify CMakeLists, fix googletest URL in readme.

Add useful utilities to the TestFixture class.  Also make it conform to
go/gunit recommendations about setup/teardown.
2015-10-26 12:52:01 -04:00
Dejan Mircevski
f184109d7b Move ImmediateInt tests into their own file.
This is in preparation of adding many more tests in accordance with the
evolved spec.

Also sort the test-source lines in CMakeLists.
2015-10-26 12:52:01 -04:00