mirror of
https://github.com/lune-org/lune.git
synced 2024-12-12 21:10:36 +00:00
23 lines
691 B
Text
23 lines
691 B
Text
local fs = require("@lune/fs")
|
|
local roblox = require("@lune/roblox")
|
|
|
|
local modelDirs = {}
|
|
for _, dirName in fs.readDir("tests/roblox/rbx-test-files/places") do
|
|
table.insert(modelDirs, "tests/roblox/rbx-test-files/places/" .. dirName)
|
|
end
|
|
|
|
for _, modelDir in modelDirs do
|
|
local modelFileBinary = fs.readFile(modelDir .. "/binary.rbxl")
|
|
local modelFileXml = fs.readFile(modelDir .. "/xml.rbxlx")
|
|
|
|
local modelBinary = roblox.deserializeModel(modelFileBinary)
|
|
local modelXml = roblox.deserializeModel(modelFileXml)
|
|
|
|
for _, modelInstance in modelBinary do
|
|
assert(modelInstance:IsA("Instance"))
|
|
end
|
|
|
|
for _, modelInstance in modelXml do
|
|
assert(modelInstance:IsA("Instance"))
|
|
end
|
|
end
|