1
0
réplica de https://github.com/coolaj86/ajquery.js.git sincronizado 2024-11-16 17:29:02 +00:00

test: commonjs can be required

Este cometimento está contido em:
AJ ONeal 2024-08-29 17:00:20 -06:00
ascendente cef7e822eb
cometimento b47f4eeb31
Não foi encontrada uma chave conhecida para esta assinatura, na base de dados
ID da chave GPG: F1D692A76F70CF98

21
tests/commonjs.cjs Ficheiro normal
Ver ficheiro

@ -0,0 +1,21 @@
"use strict";
let AJQueryDefault = require("../");
let AJQueryExplicit = require("../ajquery.cjs");
if (!AJQueryDefault.$) {
throw new Error("did not export $ correctly");
}
if (!AJQueryDefault.$$) {
throw new Error("did not export $$ correctly");
}
if (AJQueryDefault.$ !== AJQueryExplicit.$) {
throw new Error("exported $s do not match");
}
if (AJQueryDefault.$$ !== AJQueryExplicit.$$) {
throw new Error("exported $$s do not match");
}
console.log(`\x1b[34mPASS\x1b[33m`);