add kotl mode add cell tests#767
Merged
Merged
Conversation
Owner
|
All visible kotl cells are descendents of the too-level invisible 0 cell. So the first child of the 0 cell is the #1 cell, first visible in the outline.
You can attach global properties like :title to the 0 cell.
…-- Bob
On Jul 29, 2025, at 10:16 AM, Mats Lidell ***@***.***> wrote:
The behavior when called with argument 0 seems wrong. It adds in all
cases a first cell in the kotl and not the first child of the cells
parent.
|
Owner
|
Please rewrite the Note and code if need be with the info I just provided and then I’ll review it. Thanks.
…-- Bob
On Jul 29, 2025, at 6:11 PM, Robert Weiner ***@***.***> wrote:
All visible kotl cells are descendents of the too-level invisible 0 cell. So the first child of the 0 cell is the #1 cell, first visible in the outline.
You can attach global properties like :title to the 0 cell.
-- Bob
> On Jul 29, 2025, at 10:16 AM, Mats Lidell ***@***.***> wrote:
>
> The behavior when called with argument 0 seems wrong. It adds in all
> cases a first cell in the kotl and not the first child of the cells
> parent.
|
Test the current behavior and leave discussion of changed behavior outside of the PR.
Collaborator
Author
I have removed the comment from the "Note section" above about the behavior of the function There is one issue in |
matsl
commented
Jul 31, 2025
Comment on lines
+1256
to
+1257
| ;; (should (kotl-mode:first-cell-p))) ;; <= EXPECTED | ||
| (should (string= (kcell-view:label (point)) "2"))) ;; FAIL: Actual. |
Collaborator
Author
There was a problem hiding this comment.
The cell should be added at the start of the outline. i.e. label=1 but is added after i.e. label=2.
rswgnu
approved these changes
Aug 2, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Add:
Why
Functions are lacking tests.
Note
Using a temp buffer
These tests uses a new way of testing kotl-mode by combining
erase-bufferand
cl-fletwithwith-temp-buffer. A local function is used that erases thebuffer and then calls
kotl-modewhich initializes the buffer. That way onetemp buffer can be used over and over again with greater speed and less
file creation and deletion.
If there are no problems with using a temp buffer with
kotl-modethen I think that can be applied for more of the kotl-mode tests and
maybe even for more of our tests.