mirror of
https://github.com/drewcassidy/quicktex.git
synced 2024-09-13 06:37:34 +00:00
test for index errors on BC1
This commit is contained in:
parent
fea4d6c2b1
commit
b35c7d5ae9
@ -104,6 +104,11 @@ class TestBC1Texture(unittest.TestCase):
|
|||||||
|
|
||||||
self.assertEqual(self.tex[-1, -1], self.tex[self.wb - 1, self.hb - 1], 'incorrect negative subscripting')
|
self.assertEqual(self.tex[-1, -1], self.tex[self.wb - 1, self.hb - 1], 'incorrect negative subscripting')
|
||||||
|
|
||||||
|
with self.assertRaises(IndexError):
|
||||||
|
thing = self.tex[self.wb, self.hb]
|
||||||
|
with self.assertRaises(IndexError):
|
||||||
|
thing = self.tex[-1 - self.wb, -1 - self.hb]
|
||||||
|
|
||||||
def test_buffer(self):
|
def test_buffer(self):
|
||||||
"""Test the buffer protocol of BC1Texture"""
|
"""Test the buffer protocol of BC1Texture"""
|
||||||
mv = memoryview(self.tex)
|
mv = memoryview(self.tex)
|
||||||
|
Loading…
Reference in New Issue
Block a user