Commit Graph

97 Commits

Author SHA1 Message Date
Robert Alonso
c643aecf02 refactor: optionally output log if _standardTest fails
Defaults True for backwards compatibility
2024-11-11 23:52:41 +00:00
Robert Alonso
69e2360329 test: allow multiple diff files to be consumed
This sets up the ability to have one diff file
create a simulated filesystem and a second to
simulate an edit of an existing file
2024-11-11 23:52:41 +00:00
Robert Alonso
872a997803 test: add tests to capture additional known issues
These tests capture the existing issues #234 and
issue #235. As no solution is in place yet, they're
marked as expected failures.
2024-11-11 23:52:36 +00:00
Robert Alonso
2997380286 test: added tests for known bugs
Added tests for issues #224/#225 and #229. Since
these are known bugs, the tests are currently
marked as expected failures. Once the solution
is implemented, that designation can be removed
and we'll still keep the test to make sure there
aren't any regressions.
2024-11-10 04:28:37 +00:00
Robert Alonso
30b3d43dec refactor: consolidate test classes
I initially thought it a good idea to split these
up, but it led to a lot of unnnecessary code
redundancy. This is a better approach.
2024-11-09 19:56:03 +00:00
Robert Alonso
325fbaf03b test: add additional test demonstrating current bug
Added a test which demonstrates a current bug where
if multiple TODOs with the same title appear in
the diff of the same file, only one of those issues
will have its URL succesfully inserted.
(Specifically, the first from the top.) As such,
the test is configured as an expected failure until
such time as the bug can be fixed.
2024-11-09 19:28:09 +00:00
Robert Alonso
61cb584226 refactor: split unit test class to have a common base class 2024-11-09 19:28:09 +00:00
Robert Alonso
d57788aa0b fix: split diff file to allow process_diff unit test to pass
The diff file has a couple of hunks which for
some unknown reason have parsing issues which
result in the wrong line being detected for where
the TODO is. This causes the issue URL insertion
to fail. That's its own issue that should be
investigated, but in order to allow the process_diff
unit test to pass, the diff file is being split
into two to isolate the trouble-causing hunks.
2024-11-09 19:28:09 +00:00
Robert Alonso
246bf5d5bf fix: fix additional formatting issues with diff file
Wrong line numbering is causing issue URLs to not
be inserted when processing this diff file
2024-11-09 19:28:09 +00:00
Robert Alonso
cd754de86c test: print message when issue URL has actually been inserted
Insertion of the URL is different from simply
creating/updating the issue, so we want to have
this level of output to ensure that as many
file updates as expected are actually occurring.

Note: The unit test is currently failing!
2024-11-09 19:28:08 +00:00
Robert Alonso
590a050199 test: add test to exercise main's process_diff()
Reads the diff file to generate a simulated
filesystem, inserts the URL comments into these
new files, and then parses the output to confirms
that all of the issues that were expected to be
created were created.
2024-11-09 19:28:08 +00:00
Robert Alonso
da6872a340 refactor: clean up and split off diff file
test_new.diff had some issues which would cause
errors if trying to actually use the diff file
with 'patch' to create the files it references.

1) had some line numbers which were invalid
2) had path specifications and, unfortunately,
   'patch' does not support creating absent directories

The file has been cleaned up to have the create
line numbers and to assume that all files are at
the root.

Additionally, for the few cases where the diff
file referred to an edit rather than creation of a
whole new file, those diff hunks were moved into a
new, separate, file.

There is no functional change with this commit,
but it sets up future test features.
2024-11-09 19:28:08 +00:00
Alastair Mooney
4b44510149
Update test_todo_parser.py
Fix import error
2024-11-05 09:51:15 +00:00
Robert Alonso
649e50253b test: add unittest to run mypy
New unittest file consists of two tests. Both
run mypy, but one does so with arguments that are
expected to allow the test to pass. The other does
not provide those arguments and is expected to fail.
The expected failure is intentional, to serve as
an ongoing reminder to try to 1) move towards having
strict typing in the codebase and to 2) not
add any additional errors/warnings in the meantime.

Separated requirements into runtime (requirements.txt)
and additional development (requirements-dev.txt).
Modified devcontainer and workflow to reflect the
change.
2024-10-28 18:38:59 +00:00
Robert Alonso
67fd1f496c fix: reset modified environment variables after test
CustomLanguageTest was modifying a few environment
variables and not restoring them when complete. This
led to problems for later tests that expected those
variables to be at their default values.
2024-10-25 18:54:29 +00:00
Alex Harris
220a09bb7c test: Added tests for TOML support 2024-10-11 18:15:04 +01:00
Alastair Mooney
92f6bda7f0
Update test_todo_parser.py 2024-10-11 10:24:24 +01:00
Miguel Palhas
64aac3bc8a code review 2024-10-09 18:21:46 +01:00
Miguel Palhas
d6f93f3748 code review 2024-10-08 15:57:45 +01:00
Miguel Palhas
4f3709febb code review 2024-10-08 12:32:18 +01:00
Miguel Palhas
94022cee51 code review 2024-10-08 12:16:19 +01:00
Miguel Palhas
7b5d19e941 code review 2024-10-08 12:02:02 +01:00
Miguel Palhas
e88cba0c82 code review 2024-10-08 11:57:17 +01:00
Miguel Palhas
26ed78e3f4 code review 2024-10-08 11:55:07 +01:00
alstr
f8090bda34 Update tests 2024-09-25 13:12:26 +01:00
Alastair Mooney
c49e159070
Update test_todo_parser.py 2024-09-25 13:01:51 +01:00
Alastair Mooney
f7cea8d10c
Merge branch 'master' into master 2024-09-25 12:54:20 +01:00
alstr
2f462edd70 Merge master into v5 2024-09-24 14:31:16 +01:00
alstr
935bd1b4d0 Update tests 2024-09-24 14:14:28 +01:00
Kevin Ge
6ee994070c fix: number of Starlark tests in comment 2024-08-05 22:41:00 -07:00
Kevin Ge
1ff063b19e fix: check filename if no extensions match 2024-08-05 22:38:54 -07:00
klarkc
7d8b984900
Add Agda doc and tests 2024-07-11 16:29:45 -03:00
klarkc
fe5e34d9ad
Add support for PureScript 2024-07-11 16:16:15 -03:00
unclebabykern
8ba861435d test: add TSX closed issue tests and merge JSON 2024-07-03 18:00:20 -06:00
unclebabykern
2398638d34 cleanup redundant JS test func and add tsx 2024-07-01 17:48:55 -06:00
unclebabykern
e01c95d094 add TSX extension new test 2024-07-01 17:47:49 -06:00
unclebabykern
3a40c001a9 remove sneaky semicolon 2024-05-29 12:19:37 -06:00
unclebabykern
a3b911658e add liquid comment syntax w/ tests
Includes single line comment syntax with # that ignores block wrap tag requirement (e.g. {% %} enclosing line comments) for functional usage.
2024-05-29 12:17:56 -06:00
Aingeru
2bda10fabb Added support for makefile language.
Signed-off-by: Aingeru <aingeru.develop@gmail.com>
2024-03-12 12:49:15 +01:00
elftausend
401dca3ded Add support for .cu files 2024-02-16 17:10:20 +01:00
alstr
4453da85d8 Fix URL 2024-01-01 09:38:09 +00:00
Christoph Koschel
493e0c4993 Fixed typo 2023-12-31 18:06:59 +01:00
Christoph Koschel
f95e764cfd Change costume language test url to main repo 2023-09-30 20:09:39 +02:00
Christoph Koschel
952f3d6c85 Added unit tests 2023-09-30 19:39:59 +02:00
Christoph Koschel
b27611eed1 Create costume languages testing file 2023-09-30 19:25:48 +02:00
Christoph Koschel
008d51b5ea Update unit tests 2023-09-11 11:04:43 +02:00
Alastair Mooney
c5da50f1dd
Update test_todo_parser.py 2023-09-07 14:08:55 +01:00
Alastair Mooney
301fb433a3
Update test_todo_parser.py 2023-09-07 13:57:23 +01:00
Christopher Dehner
d2cd9ce383 add tests for VBA component files 2023-08-28 15:34:21 -04:00
Christoph Koschel
b11a016430 Unit tests for testing escaping 2023-07-08 21:19:27 +02:00