oops
This commit is contained in:
parent
2468c4e98b
commit
cc83c1318e
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "@lingdocs/pashto-inflector",
|
"name": "@lingdocs/pashto-inflector",
|
||||||
"version": "3.9.8",
|
"version": "4.0.0",
|
||||||
"author": "lingdocs.com",
|
"author": "lingdocs.com",
|
||||||
"description": "A Pashto inflection and verb conjugation engine, inculding React components for displaying Pashto text, inflections, and conjugations",
|
"description": "A Pashto inflection and verb conjugation engine, inculding React components for displaying Pashto text, inflections, and conjugations",
|
||||||
"homepage": "https://verbs.lingdocs.com",
|
"homepage": "https://verbs.lingdocs.com",
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import { psJSXMap, JSXMap } from "./jsx-map";
|
import { psJSXMap } from "./jsx-map";
|
||||||
|
|
||||||
test("psJSXMap should work with f as a target", () => {
|
test("psJSXMap should work with f as a target", () => {
|
||||||
const input = { p: <>زه کور ته <strong>ځم</strong></>, f: <>zu kor ta <strong>dzum</strong></> };
|
const input = { p: <>زه کور ته <strong>ځم</strong></>, f: <>zu kor ta <strong>dzum</strong></> };
|
||||||
|
@ -18,9 +18,3 @@ test("psJSXMap will error if given an uneven/unbalanced pair of JSX Elements", (
|
||||||
psJSXMap(input, "p", (ps) => ps.p.replace(/ځ/g, "ز"));
|
psJSXMap(input, "p", (ps) => ps.p.replace(/ځ/g, "ز"));
|
||||||
}).toThrow("error mapping out PsJSX - unbalanced trees");
|
}).toThrow("error mapping out PsJSX - unbalanced trees");
|
||||||
});
|
});
|
||||||
|
|
||||||
test("plain JSX map util", () => {
|
|
||||||
const input = <>this <em>will be <strong>transformed</strong></em> <span>nicely</span></>;
|
|
||||||
const output = JSXMap(input, (s) => s.toUpperCase());
|
|
||||||
expect(output).toEqual(<>THIS <em>WILL BE <strong>TRANSFORMED</strong></em> <span>NICELY</span></>);
|
|
||||||
});
|
|
Loading…
Reference in New Issue