editorutils.spec.js (hoppscotch-2.0.0) | : | editorutils.spec.js (hoppscotch-2.1.0) | ||
---|---|---|---|---|
skipping to change at line 18 | skipping to change at line 18 | |||
}) | }) | |||
test("returns 'xml' for valid XML mimes", () => { | test("returns 'xml' for valid XML mimes", () => { | |||
expect(getEditorLangForMimeType("application/xml")).toMatch("xml") | expect(getEditorLangForMimeType("application/xml")).toMatch("xml") | |||
}) | }) | |||
test("returns 'html' for valid HTML mimes", () => { | test("returns 'html' for valid HTML mimes", () => { | |||
expect(getEditorLangForMimeType("text/html")).toMatch("html") | expect(getEditorLangForMimeType("text/html")).toMatch("html") | |||
}) | }) | |||
test("returns 'plain_text' for plain text mime", () => { | test("returns 'text/x-yaml' for plain text mime", () => { | |||
expect(getEditorLangForMimeType("text/plain")).toMatch("plain_text") | expect(getEditorLangForMimeType("text/plain")).toMatch("text/x-yaml") | |||
}) | }) | |||
test("returns 'plain_text' for unimplemented mimes", () => { | test("returns 'text/x-yaml' for unimplemented mimes", () => { | |||
expect(getEditorLangForMimeType("image/gif")).toMatch("plain_text") | expect(getEditorLangForMimeType("image/gif")).toMatch("text/x-yaml") | |||
}) | }) | |||
test("returns 'plain_text' for null/undefined mimes", () => { | test("returns 'text/x-yaml' for null/undefined mimes", () => { | |||
expect(getEditorLangForMimeType(null)).toMatch("plain_text") | expect(getEditorLangForMimeType(null)).toMatch("text/x-yaml") | |||
expect(getEditorLangForMimeType(undefined)).toMatch("plain_text") | expect(getEditorLangForMimeType(undefined)).toMatch("text/x-yaml") | |||
}) | }) | |||
}) | }) | |||
End of changes. 3 change blocks. | ||||
7 lines changed or deleted | 7 lines changed or added |