Spaces:
Running
Running
Download source/src/App.test.js from divergent-tech/nlt-coding-agent: direct link, hf CLI and curl.
- Browser
- Download file 479 Bytes
-
https://huggingface.co/spaces/divergent-tech/nlt-coding-agent/resolve/main/source/src/App.test.js
- Command line
-
hf download hf://spaces/divergent-tech/nlt-coding-agent/source/src/App.test.js
-
curl -L -o App.test.js https://huggingface.co/spaces/divergent-tech/nlt-coding-agent/resolve/main/source/src/App.test.js
479 Bytes
| import '@testing-library/jest-dom'; | |
| import { render, screen, fireEvent } from '@testing-library/react'; | |
| import App from './App'; | |
| test('renders title', () => { | |
| render(<App />); | |
| expect(screen.getByText(/NLT Coding Agent/i)).toBeInTheDocument(); | |
| }); | |
| test('rejects empty prompt', () => { | |
| render(<App />); | |
| const button = screen.getByRole('button', { name: /send/i }); | |
| fireEvent.click(button); | |
| expect(screen.getByText(/Prompt cannot be empty/i)).toBeInTheDocument(); | |
| }); | |