mirror of
https://github.com/barkeser2002/minecraft-data.git
synced 2026-11-24 04:46:14 +03:00
* 🎈 Add Minecraft pc 1.21.9 data * Delete .github/helper-bot/issue.md * [Auto] Apply generated data from PrismarineJS/minecraft-data-generator#58 * feat: add debug packets and code of conduct support for pc 1.21.9 (#1116) Co-authored-by: Rich Young <ry@richyoung.ca> * chore: sync protocol json with yaml (#1117) fixes 1.21.8 and 1.21.9 Co-authored-by: Rich Young <code@richyoung.ca> * Add loginPacket.json for Minecraft 1.21.9 (#1125) * Add loginPacket.json for Minecraft 1.21.9 Adds the missing loginPacket.json file needed for 1.21.9 server support. Copied from 1.21.3 as they share similar login packet structure. * adding ci.yml * Refactor CI workflow for improved structure and clarity * Pc 1.21.9 (#1141) * 🎈 Add Minecraft pc 1.21.10 data * [Auto] Apply generated data from PrismarineJS/minecraft-data-generator#61 * Add loginPacket.json * Update features.json * Update protocol * 1.21.9 --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * sync * update protocol * build * update * add 1.21.10->1.21.9 to dataPaths * Fix packet_tracked_waypoint (#1138) * Fix packet_tracked_waypoint * Fix packet_tracked_waypoint * Fix packet_tracked_waypoint * sync * update readme * entity metadata fixes --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: extremeheat <extreme@protonmail.ch> Co-authored-by: Rich Young <916491+richnetdesign@users.noreply.github.com> Co-authored-by: Rich Young <ry@richyoung.ca> Co-authored-by: Rich Young <code@richyoung.ca> Co-authored-by: HenkjanvDiermen <henkjanvandiermen@gmail.com> Co-authored-by: SuperGamerTron <45374546+SuperGamerTron@users.noreply.github.com> Co-authored-by: Yaode_owo <95167013+Yaodeowo@users.noreply.github.com>
36 lines
1.2 KiB
JavaScript
36 lines
1.2 KiB
JavaScript
/* eslint-env mocha */
|
|
|
|
const fs = require('fs')
|
|
const { join } = require('path')
|
|
const assert = require('assert')
|
|
|
|
describe('audit dataPaths', function () {
|
|
const dataPaths = require('../../../data/dataPaths.json')
|
|
it('should have a dataPath for each file', function () {
|
|
require('./version_iterator')(function (p, versionString) {
|
|
const [type, version] = versionString.split(' ')
|
|
const dp = dataPaths[type][version]
|
|
if (fs.existsSync(p)) {
|
|
const files = fs.readdirSync(p).map(f => f.split('.')[0])
|
|
for (const file of files) {
|
|
assert(dp[file], `missing dataPath for ${type} ${version} ${file}`)
|
|
}
|
|
}
|
|
})
|
|
})
|
|
|
|
it('dataPath should point to valid files', function () {
|
|
for (const version in dataPaths) {
|
|
for (const type in dataPaths[version]) {
|
|
const dp = dataPaths[version][type]
|
|
for (const file in dp) {
|
|
const path = dp[file]
|
|
const p = join(__dirname, '../../../data/' + path + '/' + file)
|
|
const exists = fs.existsSync(p + '.json') || fs.existsSync(p + '.yml')
|
|
assert(exists, `missing file for ${type} ${version} ${file}, path: ${p}`)
|
|
}
|
|
}
|
|
}
|
|
})
|
|
})
|