mirror of
https://github.com/love2d/love.git
synced 2026-08-12 16:40:57 +02:00
e03b2db08b
- Added tests for all obj creation, transformation, window + system info graphics methods
- Added half the state methods for graphics + added placeholders for missing drawing methods
- Added TestMethod:assertNotNil() for quick nil checking
- Added time total to the end of each module summary in console log to match file output
- Removed a bunch of unessecary nil checks
- Removed :release() from test methods, collectgarbage("collect") is called between methods instead
- Renamed /output to /examples to avoid confusion
- Replaced love.filesystem.newFile with love.filesystem.openFile
- Replaced love.math.noise with love.math.perlinNoise / love.math.simplexNoise
- Fixed newGearJoint throwing an error in 12 as body needs to be dynamic not static now
- Some general cleanup, incl. better comments and time format in file output
27 lines
918 B
Lua
27 lines
918 B
Lua
-- love.image
|
|
|
|
|
|
-- love.image.isCompressed
|
|
-- @NOTE really we need to test each of the files listed here:
|
|
-- https://love2d.org/wiki/CompressedImageFormat
|
|
-- also need to be platform dependent (e.g. dxt not suppored on phones)
|
|
love.test.image.isCompressed = function(test)
|
|
test:assertEquals(true, love.image.isCompressed('resources/love.dxt1'),
|
|
'check dxt1 valid compressed image')
|
|
end
|
|
|
|
|
|
-- love.image.newCompressedData
|
|
-- @NOTE this is just basic nil checking, full obj test are in objects.lua
|
|
love.test.image.newCompressedData = function(test)
|
|
test:assertObject(love.image.newCompressedData('resources/love.dxt1'))
|
|
end
|
|
|
|
|
|
-- love.image.newImageData
|
|
-- @NOTE this is just basic nil checking, full obj test are in objects.lua
|
|
love.test.image.newImageData = function(test)
|
|
test:assertObject(love.image.newImageData('resources/love.png'))
|
|
test:assertObject(love.image.newImageData(16, 16, 'rgba8', nil))
|
|
end
|