Repository navigation
Conversation
6f64829 to
be685e9
Compare
|
@kommander Please ignore the fact that I sometimes use If this rings a bell and you know a fix, please let me know. (I'm using vscode) |
|
I am not using a debugger at the moment, so I can't really help with the breakpoint problem, although I suspect the solid plugin compilation messing up the line numbers, the issue exists in tests where in failures the stack traces are wrong. Maybe @Adictya has an idea here. Regarding the test setup, that is a good start. However I am a bit scared by the many unit mocks. I would rather mock less and at a lower level, so it's more like "integration" tests for the tui, where only the interface to the server/sdk is mocked, so we can control model responses, errors etc. and test how the whole tui actually reacts to it. |
|
That makes sense, though I think a few more context providers should be mocked by default in addition to server/sdk. Please see commit d86a5cc#diff-4ac50cbf1a587d44e1de3cca0938ee733680bdb151025778d721a6797477d123R19 where I disable some mocks. I tried to choose a reasonable subset, let me know if you disagree. |
I debug directly via |
|
Yeah I also do |
|
@kommander Tests are coming along nicely. I expect to have a bunch more ready by end of day. Do you have any special ones to pay attention to? Btw I also ran into this: 865d610#diff-136aadfe331bad702903358a242e704fbd853464f9e83c6fcd4d54fd3c71258aR353 |
|
Cool, I'll review in a bit. Is that segfault reproducible somehow in a test? |
|
Happens in home.test.ts -> Model dialog -> "should open model dialog". When I skip that test the issue doesn't happen. At the moment I'm writing the error is always a segfault, but earlier today it would sometimes segfault and sometimes throw |
- Add snapshot test for autocomplete menu when typing "/" - Reformat existing test imports and expectations for consistency
- Test that typing "/ex" narrows to "/exit" in autocomplete - Test that pressing enter after "/ex" triggers the exit action
Temporarily skip the "prompt should start a new session" test that is currently failing. Marked with TODO to indicate this should be re-enabled once the underlying issue is resolved.
4c6d112 to
625d321
Compare
f1dc981 to
3e15a39
Compare
f8ee907 to
6a9856d
Compare
00637c0 to
71e0ba2
Compare
f1ae801 to
08fa7f7
Compare
|
Closing this pull request because it has had no updates for more than 60 days. If you plan to continue working on it, feel free to reopen or open a new PR. |
@kommander I have created a comprehensive mock context setup and a few tests to get things going.
My plan was to add tests all day today (Monday). If you are not in a super hurry to maximize coverage, I would like to tinker a bit with the utility functions. Otherwise, we can work on different tests in parallel if you want.
Todos: