mirror of
https://github.com/samiyev/puaros.git
synced 2025-12-27 23:06:54 +05:00
feat(ipuaro): implement v0.1.0 foundation
- Project setup with tsup, vitest, ESM support - Domain entities: Session, Project - Value objects: FileData, FileAST, FileMeta, ChatMessage, ToolCall, ToolResult, UndoEntry - Service interfaces: IStorage, ILLMClient, ITool, IIndexer, IToolRegistry - Shared: Config (zod), IpuaroError, utils (hash, tokens), Result type - CLI with placeholder commands (start, init, index) - 91 unit tests with 100% coverage - Fix package scope @puaros -> @samiyev in CLAUDE.md
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
import { describe, it, expect } from "vitest"
|
||||
import { createEmptyFileAST } from "../../../../src/domain/value-objects/FileAST.js"
|
||||
|
||||
describe("FileAST", () => {
|
||||
describe("createEmptyFileAST", () => {
|
||||
it("should create empty AST with all arrays empty", () => {
|
||||
const ast = createEmptyFileAST()
|
||||
|
||||
expect(ast.imports).toEqual([])
|
||||
expect(ast.exports).toEqual([])
|
||||
expect(ast.functions).toEqual([])
|
||||
expect(ast.classes).toEqual([])
|
||||
expect(ast.interfaces).toEqual([])
|
||||
expect(ast.typeAliases).toEqual([])
|
||||
expect(ast.parseError).toBe(false)
|
||||
expect(ast.parseErrorMessage).toBeUndefined()
|
||||
})
|
||||
})
|
||||
})
|
||||
Reference in New Issue
Block a user