Builtin Library
README.md
Test.ownership
Which of the things a suite can leave behind are the engine's own. The test framework reads these when it judges what a suite handed back: what the engine keeps for itself is no suite's to answer for.
engineOwnedModule(key)answers whether a require-cache key names a module of the built-in library or one of the VM's standard libraries.engineOwnedBuffer(name)answers whether the named GPU buffer was made through the substrate by a module of the engine's.substrateNames()answers the names every named GPU buffer stands under right now, or nil when the substrate cannot be read.engineComputeRow(row, named)answers whether a compute resource row is one of the engine's own: a params ring page, the__paramsuniform of a program the engine or a.computeShaderasset compiled, an arena page, or a buffer a module of the engine's made.namedissubstrateNames()read with the rows.
local Ownership = require("@builtin::assetTypes.testSuite.shared.ownership")
assert(Ownership.engineOwnedModule("@builtin::modules.json"))
assert(not Ownership.engineOwnedModule("/zero/source/mine.luau"))
print(Ownership.substrateNames())