15 lines
512 B
JavaScript
15 lines
512 B
JavaScript
import assert from 'node:assert/strict'
|
|
import test from 'node:test'
|
|
import { buildControllerBundle } from './build-controller-release-bundle.mjs'
|
|
|
|
test('rejects a formatted but nonexistent or non-current source commit', () => {
|
|
assert.throws(
|
|
() => buildControllerBundle({
|
|
version: '1.2.2',
|
|
sourceCommit: '0000000000000000000000000000000000000000',
|
|
repository: '../..',
|
|
output: '/tmp/hololake-controller-bundle-must-not-exist',
|
|
}),
|
|
/SOURCE_COMMIT_NOT_CURRENT_HEAD/,
|
|
)
|
|
})
|