mirror of
https://github.com/fjdu/obsidian-latex-unicode.git
synced 2026-07-22 07:30:30 +00:00
31 lines
751 B
TypeScript
31 lines
751 B
TypeScript
import { expect } from 'chai';
|
||
import { replace } from './replace';
|
||
|
||
|
||
describe('Symbols', () => {
|
||
describe('replace alpha', () => {
|
||
it('converts', done => {
|
||
expect(replace('\\alpha')).to.equal('α');
|
||
done();
|
||
});
|
||
});
|
||
|
||
describe('combining mark', () => {
|
||
it('adds dot to a', done => {
|
||
expect(replace('\\dot{a}')).to.equal('ȧ');
|
||
done();
|
||
});
|
||
it('adds dot to alpha', done => {
|
||
expect(replace('\\dot{\\alpha}')).to.equal('α̇');
|
||
done();
|
||
});
|
||
it('empty combining char', done => {
|
||
expect(replace('\\breve{}')).to.equal('˘');
|
||
done();
|
||
});
|
||
it('incomplete combining char', done => {
|
||
expect(replace('\\breve{')).to.equal('\\breve{');
|
||
done();
|
||
});
|
||
});
|
||
});
|