- Enhanced readme with detailed API documentation - Added real-world usage examples and best practices - Updated legal section to Task Venture Capital GmbH - Updated CI/CD workflow configurations - Updated dependencies to latest versions - Removed obsolete gitlab-ci.yml
46 lines
1.4 KiB
TypeScript
46 lines
1.4 KiB
TypeScript
import { expect, tap } from '@git.zone/tstest/tapbundle';
|
|
|
|
import * as consolecolor from '../ts/index.js';
|
|
|
|
tap.test('should produce a blue font', async () => {
|
|
console.log(
|
|
consolecolor.coloredString('this is a blue font, no background', 'blue'),
|
|
);
|
|
});
|
|
|
|
tap.test('should produce a red string with green background', async () => {
|
|
console.log(
|
|
consolecolor.coloredString(
|
|
'this is a red font with green background',
|
|
'red',
|
|
'green',
|
|
),
|
|
);
|
|
});
|
|
|
|
tap.test('should produce different font colors', async () => {
|
|
console.log(
|
|
consolecolor.coloredString('blue', 'blue'),
|
|
consolecolor.coloredString('brown', 'brown'),
|
|
consolecolor.coloredString('red', 'red'),
|
|
consolecolor.coloredString('orange', 'orange'),
|
|
consolecolor.coloredString('green', 'green'),
|
|
consolecolor.coloredString('pink', 'pink'),
|
|
consolecolor.coloredString('cyan', 'cyan'),
|
|
);
|
|
});
|
|
|
|
tap.test('should produce different background colors', async () => {
|
|
console.log(
|
|
consolecolor.coloredString('blue', 'white', 'blue'),
|
|
consolecolor.coloredString('brown', 'white', 'brown'),
|
|
consolecolor.coloredString('red', 'white', 'red'),
|
|
consolecolor.coloredString('orange', 'white', 'orange'),
|
|
consolecolor.coloredString('green', 'white', 'green'),
|
|
consolecolor.coloredString('pink', 'white', 'pink'),
|
|
consolecolor.coloredString('cyan', 'white', 'cyan'),
|
|
);
|
|
});
|
|
|
|
export default tap.start();
|