Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lib/features.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
{
"name": "proportionalLiquidGravity",
"description": "Liquid gravity is a proportion of normal gravity",
"versions": ["1.13", "1.14", "1.15", "1.16", "1.17", "1.18", "1.19", "1.20", "1.21", "26.1"]
"versions": ["1.13", "1.14", "1.15", "1.16", "1.17", "1.18", "1.19", "1.20", "1.21", "26.1", "26.2"]
},
{
"name": "velocityBlocksOnCollision",
Expand Down
16 changes: 16 additions & 0 deletions test/liquidGravity.test.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
/* eslint-env mocha */

const expect = require('expect')
const features = require('../lib/features.json')

describe('Liquid gravity feature', () => {
it('proportionalLiquidGravity should include 26.1 and 26.2', () => {
// Physics() throws if a version's majorVersion matches neither independentLiquidGravity nor
// proportionalLiquidGravity (see index.js) — 26.2 was missing here, breaking Physics()
// construction for every consumer as soon as minecraft-data ships data for 26.2.
const proportional = features.find(f => f.name === 'proportionalLiquidGravity')
expect(proportional).toBeTruthy()
expect(proportional.versions).toContain('26.1')
expect(proportional.versions).toContain('26.2')
})
})
Loading