Dorian 0d073fa89e Add comprehensive installation and setup documentation
- Add GETTING_STARTED.md with quick start guide and development modes
- Add INSTALL.sh automated installation script
- Add INSTALLATION_CHECKLIST.md, INSTALLATION_SUCCESS.md, and INSTALLATION_SUMMARY.md
- Add QUICK_REFERENCE.md for common commands
- Add SETUP_GUIDE.md with detailed setup instructions
- Update README.md with improved project overview
- Add did-wallet app dependencies and node_modules
2026-01-27 17:18:21 +00:00

29 lines
522 B
JavaScript

'use strict'
const test = require('tape')
const SparseArray = require('../')
let arr
test('allows to be constructed', (t) => {
arr = new SparseArray()
t.end()
})
test('compact array is empty', (t) => {
t.deepEqual(arr.compactArray(), [])
t.end()
})
test('compact array containing one pos', (t) => {
arr.set(10, '10')
t.deepEqual(arr.compactArray(), ['10'])
t.end()
})
test('compact array containing two positions', (t) => {
arr.set(5, '5')
t.deepEqual(arr.compactArray(), ['5', '10'])
t.end()
})