Skip to content

Commit

Permalink
Merge pull request #143 from DosangGu/master
Browse files Browse the repository at this point in the history
Add xaml support
  • Loading branch information
alstr authored Feb 9, 2023
2 parents 1f9b697 + e2ff495 commit dd82ee6
Show file tree
Hide file tree
Showing 4 changed files with 43 additions and 3 deletions.
14 changes: 13 additions & 1 deletion syntax.json
Original file line number Diff line number Diff line change
Expand Up @@ -683,5 +683,17 @@
}
}
]
},
{
"language": "XML",
"markers": [
{
"type": "block",
"pattern": {
"start": "<!--",
"end": "-->"
}
}
]
}
]
]
12 changes: 12 additions & 0 deletions tests/test_closed.diff
Original file line number Diff line number Diff line change
Expand Up @@ -323,3 +323,15 @@ index a6c6cb0..25d195f 100644
- */
sum = a: b: a + b;
}
diff --git a/tests/example.xaml b/tests/example.xaml
new file mode 100644
index 0000000..a6c6cb0
--- /dev/null
+++ b/tests/example.xaml
@@ -1,4 +1,2 @@
-<!-- TODO: Add xaml support -->
-<Label Text="why"/>
-<!-- TODO: please -->
-<Label Text="ok"/>
<Label Text="There you go"/>
<Label Text="Thank you"/>
10 changes: 10 additions & 0 deletions tests/test_new.diff
Original file line number Diff line number Diff line change
Expand Up @@ -348,3 +348,13 @@ index 0000000..a6c6cb0
+ */
+ sum = a: b: a + b;
+}
diff --git a/tests/example.xaml b/tests/example.xaml
new file mode 100644
index 0000000..a6c6cb0
--- /dev/null
+++ b/tests/example.xaml
@@ -0,0 +1,4 @@
+<!-- TODO: Add xaml support -->
+<Label Text="why"/>
+<!-- TODO: please -->
+<Label Text="ok"/>
10 changes: 8 additions & 2 deletions tests/test_todo_parser.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import json
import os
import unittest
import json

from main import TodoParser


Expand Down Expand Up @@ -82,6 +83,9 @@ def test_clojure_issues(self):
def test_nix_issues(self):
self.assertEqual(count_issues_for_file_type(self.raw_issues, 'nix'), 2)

def test_xaml_issues(self):
self.assertEqual(count_issues_for_file_type(self.raw_issues, 'xml'), 2)

class ClosedIssueTests(unittest.TestCase):
# Check for removed TODOs across the files specified.
def setUp(self):
Expand Down Expand Up @@ -151,7 +155,9 @@ def test_clojure_issues(self):

def test_nix_issues(self):
self.assertEqual(count_issues_for_file_type(self.raw_issues, 'nix'), 2)


def test_xaml_issues(self):
self.assertEqual(count_issues_for_file_type(self.raw_issues, 'xml'), 2)

class IgnorePatternTests(unittest.TestCase):

Expand Down

0 comments on commit dd82ee6

Please sign in to comment.