first commit

This commit is contained in:
2025-10-10 11:30:12 +02:00
commit 3aaadfdb62
10 changed files with 10214 additions and 0 deletions

17
test.js Normal file
View File

@@ -0,0 +1,17 @@
import React from 'react';
import chalk from 'chalk';
import test from 'ava';
import {render} from 'ink-testing-library';
import App from './source/app.js';
test('greet unknown user', t => {
const {lastFrame} = render(<App />);
t.is(lastFrame(), `Hello, ${chalk.green('Stranger')}`);
});
test('greet user with a name', t => {
const {lastFrame} = render(<App name="Jane" />);
t.is(lastFrame(), `Hello, ${chalk.green('Jane')}`);
});