Workshop outcome
This commit is contained in:
@@ -0,0 +1,8 @@
|
||||
import { describe, it, expect } from "vitest";
|
||||
import { greet } from "./greet.js";
|
||||
|
||||
describe("greet", () => {
|
||||
it("returns a greeting for a given name", () => {
|
||||
expect(greet("World")).toBe("Hello, World!");
|
||||
});
|
||||
});
|
||||
@@ -0,0 +1,3 @@
|
||||
export function greet(name: string): string {
|
||||
return `Hello, ${name}!`;
|
||||
}
|
||||
Reference in New Issue
Block a user