fix(build): modernize package tooling and test setup for current git.zone build ecosystem

This commit is contained in:
2026-05-01 18:37:41 +00:00
parent deda14e669
commit 669ca2c234
10 changed files with 7038 additions and 3935 deletions
+24
View File
@@ -0,0 +1,24 @@
import { expect, tap } from '@git.zone/tstest/tapbundle';
import * as smartvalidator from '../ts/index.js';
let testValidator: smartvalidator.SmartValidator;
tap.test('first test', async () => {
testValidator = new smartvalidator.SmartValidator();
expect(testValidator).toBeInstanceOf(smartvalidator.SmartValidator);
});
tap.test('should check for being a URL', async () => {
expect(testValidator.isUrl('lossless.com')).toBeTrue();
});
tap.test('should check an IBAN', async () => {
expect(testValidator.isIban('AT95 0100 0000 0555 4915')).toBeTrue();
});
tap.test('escape email', async () => {
const escapedEmail = testValidator.escape('test@example.com');
console.log(escapedEmail);
});
export default tap.start();