[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/sql-indent 5a3ce9e52c 2/2: Add tests for #104 and #103
From: |
ELPA Syncer |
Subject: |
[elpa] externals/sql-indent 5a3ce9e52c 2/2: Add tests for #104 and #103 |
Date: |
Thu, 19 May 2022 17:58:17 -0400 (EDT) |
branch: externals/sql-indent
commit 5a3ce9e52cc3fb55ec02f3a38f43d687a9e3672d
Author: Alex Harsányi <AlexHarsanyi@gmail.com>
Commit: Alex Harsányi <AlexHarsanyi@gmail.com>
Add tests for #104 and #103
---
.github/workflows/main.yml | 2 +-
sql-indent-test.el | 5 +++++
test-data/pr104-syn.eld | 6 ++++++
test-data/pr104.sql | 3 +++
4 files changed, 15 insertions(+), 1 deletion(-)
diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml
index 1b15c3b513..4509c48b8e 100644
--- a/.github/workflows/main.yml
+++ b/.github/workflows/main.yml
@@ -10,7 +10,7 @@ jobs:
strategy:
matrix:
emacs_version:
- - 27.1
+ - 28.1
steps:
- uses: purcell/setup-emacs@master
with:
diff --git a/sql-indent-test.el b/sql-indent-test.el
index 7c092405ab..00e56cc629 100644
--- a/sql-indent-test.el
+++ b/sql-indent-test.el
@@ -493,4 +493,9 @@ information read from DATA-FILE (as generated by
"test-data/pr102.sql"
"test-data/pr102-syn.eld"))
+(ert-deftest sqlind-ert-pr104 ()
+ (sqlind-ert-check-file-syntax
+ "test-data/pr104.sql"
+ "test-data/pr104-syn.eld"))
+
;;; sql-indent-test.el ends here
diff --git a/test-data/pr104-syn.eld b/test-data/pr104-syn.eld
new file mode 100644
index 0000000000..2430e46db7
--- /dev/null
+++ b/test-data/pr104-syn.eld
@@ -0,0 +1,6 @@
+(((toplevel . 1))
+ (((create-statement table "x")
+ . 1))
+ (((create-statement table "x")
+ . 1))
+ ((toplevel . 1)))
\ No newline at end of file
diff --git a/test-data/pr104.sql b/test-data/pr104.sql
new file mode 100644
index 0000000000..46d822942b
--- /dev/null
+++ b/test-data/pr104.sql
@@ -0,0 +1,3 @@
+alter table x
+ drop constraint if exists not_unique_idx,
+ add constraint unique_idx unique (this, that);