1 | const CompositionAlgebra = require('algebra').CompositionAlgebra
|
2 | const realField = require('../src/realField')
|
3 |
|
4 | const R = CompositionAlgebra(realField)
|
5 |
|
6 | describe('CompositionAlgebra', () => {
|
7 | describe('data', () => {
|
8 | const pi = new R(Math.PI)
|
9 |
|
10 | it('is enumerable', () => {
|
11 | pi.propertyIsEnumerable('data').should.be.ok
|
12 | })
|
13 |
|
14 | it('is immutable', () => {
|
15 | ;(() => {
|
16 |
|
17 | pi.data = 2
|
18 | }).should.throwError()
|
19 | })
|
20 | })
|
21 | })
|