focus tweak for squeezeJoin - another go at fixing #216 (#221)

Fixes squeezeJoin, and in the process struct/keepif. fixes #216

Co-authored-by: Felix Roos <flix91@gmail.com>
This commit is contained in:
Alex McLean 2022-09-24 23:27:25 +01:00 committed by GitHub
parent 852f01fddd
commit 513e0d748d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 678 additions and 655 deletions

View file

@ -42,6 +42,7 @@ import {
id,
ply,
rev,
time,
} from '../index.mjs';
import { steady } from '../signal.mjs';
@ -791,6 +792,13 @@ describe('Pattern', () => {
).firstCycle(),
);
});
it('Squeezes to the correct cycle', () => {
expect(
pure(time.struct(true))._squeezeJoin().queryArc(3,4).map(x => x.value)
).toStrictEqual(
[Fraction(3.5)]
)
});
});
describe('ply', () => {
it('Can ply(3)', () => {