todo-to-issue-action/tests/test_new.diff
Marcos Soutullo Rodriguez 9e57f4e103
feat: add JSON5 support
2022-10-16 11:00:18 +01:00

308 lines
8.3 KiB
Diff

diff --git a/tests/ExampleFile.java b/tests/ExampleFile.java
new file mode 100644
index 0000000..d340f6a
--- /dev/null
+++ b/tests/ExampleFile.java
@@ -0,0 +1,13 @@
+package com.mydomain.myapp;
+
+public class JavaTests {
+ // TODO: Expand this class
+ // Do it
+ // labels: urgent
+
+ /*
+ TODO: Definitely expand this class
+ Do it ASAP
+ labels: urgent
+ */
+}
\ No newline at end of file
diff --git a/tests/example-file.php b/tests/example-file.php
new file mode 100644
index 0000000..063bb80
--- /dev/null
+++ b/tests/example-file.php
@@ -0,0 +1,23 @@
+<!DOCTYPE html>
+<html>
+<body>
+<!-- TODO: Check HTML comments work -->
+<?php
+ echo 'Testing 123';
+ // TODO: Expand this page
+ // We aren't doing anything here yet
+
+ echo 'Testing 456';
+ # TODO: Definitely expand this
+ # There needs to be some point to this file
+
+ echo 'Testing 789'
+ /*
+ * TODO: Echo a greeting instead
+ * This should work with or without the asterisk on each line
+ * labels: help wanted
+ */
+?>
+
+</body>
+</html>
\ No newline at end of file
diff --git a/tests/example_file.py b/tests/example_file.py
new file mode 100644
index 0000000..525e25d
--- /dev/null
+++ b/tests/example_file.py
@@ -0,0 +1,23 @@
+def hello_world():
+ # TODO: Come up with a more imaginative greeting
+ print('Hello world')
+
+ # TODO: Do more stuff
+ # This function should probably do something more interesting
+ # labels: help wanted
+
+def my_method(arg):
+ """
+ TODO: Second multiline comment
+ also need to be turned into task, and hopefully
+ kept together as one.
+ """
+ pass
+
+def MyClass:
+ '''
+ TODO: Third multiline comment
+ also need to be turned into task, and hopefully
+ kept together as one.
+ '''
+ pass
\ No newline at end of file
diff --git a/src/Swarm/Game/example.hs b/src/Swarm/Game/example.hs
new file mode 100644
index 0000000..0ce9b1a
--- /dev/null
+++ b/src/Swarm/Game/example.hs
@@ -0,0 +1,14 @@
+-- | Standard devices that are always installed.
+--
+-- TODO: Remove standard devices
+-- In the future, make a way to build these and just start the base
+-- out with a large supply of each?
+-- labels: redesign
+stdDeviceList =
+ ["treads", "grabber", "solar panel", "scanner", "plasma cutter"]
+
+{- | Very complicated function.
+
+TODO: Create an issue for TODO
+-}
+sum a b = a + b
diff --git a/tests/example_file.cr b/tests/example_file.cr
new file mode 100644
index 0000000..e6da2ec
--- /dev/null
+++ b/tests/example_file.cr
@@ -0,0 +1,14 @@
+# TODO: Come up with a more imaginative greeting
+puts "Greetings"
+
+# TODO: Do even more stuff
+# This function should probably do something more interesting
+# labels: help wanted
diff --git a/tests/example_file.rb b/tests/example_file.rb
new file mode 100644
index 0000000..e6da2ec
--- /dev/null
+++ b/tests/example_file.rb
@@ -0,0 +1,14 @@
+#!/usr/bin/ruby -w
+
+# TODO: Come up with a more imaginative greeting
+puts "Greetings"
+
+=begin
+TODO: Do more stuff
+This function should probably do something more interesting
+labels: help wanted
+=end
+
+# TODO: Do even more stuff
+# This function should probably do something more interesting
+# labels: help wanted
diff --git a/tests/example_file.yaml b/tests/example_file.yaml
new file mode 100644
index 0000000..6397789
--- /dev/null
+++ b/tests/example_file.yaml
@@ -0,0 +1,7 @@
+name: "TODO to Issue"
+# TODO: Write a more interesting description
+description: "Converts IDE TODO comments to GitHub issues"
+author: "Alastair Mooney"
+# TODO: Define inputs
+# Need to do this before the action is released
+# labels: urgent
diff --git a/tests/example_file.prog.abap b/src/tests/example_file.prog.abap
new file mode 100644
index 0000000..7cccc5b
--- /dev/null
+++ b/tests/example_file.prog.abap
@@ -0,0 +1,5 @@
+REPORT ztest_todo_2.
+
+DATA moo TYPE i VALUE 2.
+WRITE moo. " TODO This is an end-of-line to-do
+moo = 4. * TODO This is another end-of-line to-do
diff --git a/tests/example_file.sql b/src/tests/example_file.sql
new file mode 100644
index 0000000..7cccc5b
--- /dev/null
+++ b/src/tests/example_file.sql
@@ -0,0 +1,2 @@
+-- TODO Select all:
+SELECT * FROM Products;
diff --git a/tests/example_file.tex b/src/tests/example_file.tex
new file mode 100644
index 0000000..7cccc5b
--- /dev/null
+++ b/src/tests/example_file.tex
@@ -0,0 +1,2 @@
+% TODO Add in preamble details
+\begin{document}
+ \begin{comment}
+ TODO This document needs content
+ label: urgent
+ \end{comment}
+\end{document}
diff --git a/tests/example_file.jl b/src/tests/example_file.jl
new file mode 100644
index 0000000..7cccc5b
--- /dev/null
+++ b/src/tests/example_file.jl
@@ -0,0 +1,2 @@
+ # TODO: Hopefully this comment turns into an issue
+ print("Hello World")
+ #= TODO: Multiline comments
+ also need to be turned into task, and hopefully
+ kept together as one.
+ =#
diff --git a/tests/example_file.ahk b/src/tests/example_file.ahk
new file mode 100644
index 0000000..7cccc5b
--- /dev/null
+++ b/src/tests/example_file.ahk
@@ -0,0 +1,2 @@
+ ; TODO: Find a better way to manage hotkeys
+ ; Maybe just switch to vim??
+ #h::
+ RegRead, HiddenFiles_Status, HKEY_CURRENT_USER, Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced, Hidden
diff --git a/tests/example_file.hbs b/src/tests/example_file.hbs
new file mode 100644
index 0000000..7cccc5b
--- /dev/null
+++ b/src/tests/example_file.hbs
@@ -0,0 +1,2 @@
+ <!-- TODO: Hopefully this comment turns into a todo issue -->
+ {{!
+ TODO: Make a handlebar templtate
+ This is really just a test, but hopefully this works~!
+ }}
diff --git a/tests/example_file.org b/src/tests/example_file.org
new file mode 100644
index 0000000..7cccc5b
--- /dev/null
+++ b/src/tests/example_file.org
@@ -0,0 +1,2 @@
+ # TODO: Hopefully this comment turns into a todo issue
+ #+begin_src python
+ print("Hello World")
+ #+end_src
+ #+begin_comment
+ TODO: Multiline comments
+ also need to be turned into todos, and hopefully
+ kept together as one todo
+ #+end_comment
diff --git a/tests/example_file.scss b/src/tests/example_file.scss
new file mode 100644
index 0000000..7cccc5b
--- /dev/null
+++ b/src/tests/example_file.scss
@@ -0,0 +1,11 @@
+// TODO: Hopefully this comment turns into a todo issue
+.my-class {
+ font-weight: bold;
+ .my-second-class {
+ /* TODO: Multiline comments
+ * also need to be turned into todos, and hopefully
+ * kept together as one todo
+ */
+ text-align: center;
+ }
+}
diff --git a/tests/example_file.twig b/src/tests/example_file.twig
new file mode 100644
index 0000000..7cccc5b
--- /dev/null
+++ b/src/tests/example_file.twig
@@ -0,0 +1,6 @@
+ {# TODO: Hopefully this comment turns into a todo issue #}
+ {#
+ TODO:Multiline comments
+ also need to be turned into todos, and hopefully
+ kept together as one todo
+ #}
diff --git a/tests/example_file.md b/src/tests/example_file.md
new file mode 100644
index 0000000..7cccc5b
--- /dev/null
+++ b/src/tests/example_file.md
@@ -0,0 +1,7 @@
+ {/* TODO: Hopefully this comment turns into a todo issue */}
+ {/*
+ TODO:Multiline comments
+ also need to be turned into todos, and hopefully
+ kept together as one todo
+ */}
+ - [ ] TODO: An inline todo that's NOT a comment (what)
diff --git a/tests/example_file.mdx b/src/tests/example_file.mdx
new file mode 100644
index 0000000..7cccc5b
--- /dev/null
+++ b/src/tests/example_file.mdx
@@ -0,0 +1,7 @@
+ {/* TODO: Hopefully this comment turns into a todo issue */}
+ {/*
+ TODO:Multiline comments
+ also need to be turned into todos, and hopefully
+ kept together as one todo
+ */}
+ - [ ] TODO: An inline todo that's NOT a comment (what)
diff --git a/tests/example_file.r b/tests/example_file.r
new file mode 100644
index 0000000..525e25d
--- /dev/null
+++ b/tests/example_file.r
@@ -0,0 +1,23 @@
+hello_world <- function() {
+ # TODO: Come up with a more imaginative greeting
+ message("Hello world")
+
+ # TODO: Do more stuff
+ # This function should probably do something more interesting
+ # labels: help wanted
+}
diff --git a/tests/example_file.r b/tests/config.json5
new file mode 100644
index 0000000..525f56e
--- /dev/null
+++ b/tests/example_file.json5
@@ -0,0 +1,7 @@
+{
+ "myConfig": [
+ // GitRepository where 'Git release/tag' matches 'Helm' version
+ "itIsWonderful",
+ // TODO: Delete this line from the codebase
+ "butItHasSomePendingActivities"
+ ]
+}