diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 9410a7c..4ed0b57 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -4,14 +4,14 @@ jobs:
build:
name: Exist ${{ matrix.exist-version }} (Java ${{ matrix.java-version }}) build and test
strategy:
- fail-fast: true
+ fail-fast: false
matrix:
exist-version: [latest, 6.2.0]
- java-version: ['8', '17']
+ java-version: ['8', '21']
os: [ubuntu-latest]
exclude:
- exist-version: 6.2.0
- java-version: 17
+ java-version: 21
- exist-version: latest
java-version: 8
@@ -28,13 +28,18 @@ jobs:
run: |
sudo apt-get update
sudo apt-get install -y bats
+
- name: Maven Build
run: mvn clean package
+ - name: set min templating version from pom
+ run: |
+ echo "TEMPLATING_VERSION=$(mvn help:evaluate -Dexpression=templating.version -q -DforceStdout)" >> $GITHUB_ENV
+
- name: Add expath dependencies
working-directory: target
run: |
- wget http://exist-db.org/exist/apps/public-repo/public/templating-1.1.0.xar -O 001.xar
+ wget http://exist-db.org/exist/apps/public-repo/public/templating-${{ env.TEMPLATING_VERSION }}.xar -O 001.xar
# Install
diff --git a/.gitignore b/.gitignore
index 4fbafcd..ea9d59d 100644
--- a/.gitignore
+++ b/.gitignore
@@ -6,3 +6,4 @@ node/
.settings/
.vscode/
.DS_Store
+src/test/cypress/screenshots/
\ No newline at end of file
diff --git a/pom.xml b/pom.xml
index ca3f960..14d5b2d 100644
--- a/pom.xml
+++ b/pom.xml
@@ -49,7 +49,7 @@
1.8
6.2.0
- 1.1.0
+ 1.2.1
v18.18.2
10.2.1
diff --git a/src/main/xar-resources/modules/app.xql b/src/main/xar-resources/modules/app.xql
index 6918417..0acbcd5 100644
--- a/src/main/xar-resources/modules/app.xql
+++ b/src/main/xar-resources/modules/app.xql
@@ -108,7 +108,7 @@ function app:module($node as node(), $model as map(*), $details as xs:boolean) {
order by $order
return
- app:print-module($module, $funcsInModule, boolean($details))
+ app:print-module($module, $funcsInModule, $details)
};
declare %private function app:print-module($module as element(xqdoc:xqdoc), $functions as element(xqdoc:function)*,
diff --git a/src/test/bats/smoke-test.bats b/src/test/bats/smoke-test.bats
index 8217393..ce4b3e0 100644
--- a/src/test/bats/smoke-test.bats
+++ b/src/test/bats/smoke-test.bats
@@ -44,9 +44,3 @@
result=$(docker logs exist | grep -ow -c 'Unable to open cgroup memory limit file' || true )
[ "$result" -eq 0 ]
}
-
-@test "Reindex db" {
- run curl -s -u 'admin:' 'http://127.0.0.1:8080/exist/rest/db/apps/fundocs/modules/reindex.xql'
- [ "$status" -eq 0 ]
- echo '# ' $output >&3
-}
diff --git a/src/test/cypress/integration/fundoc_spec.cy.js b/src/test/cypress/integration/fundoc_spec.cy.js
index 3cde740..e60dcbd 100644
--- a/src/test/cypress/integration/fundoc_spec.cy.js
+++ b/src/test/cypress/integration/fundoc_spec.cy.js
@@ -2,6 +2,19 @@
///
context('Function Documentation', () => {
+ before (() => {
+ // Creat Index before running test
+ cy.request({
+ url: 'http://127.0.0.1:8080/exist/rest/db/apps/fundocs/modules/reindex.xql',
+ auth: {
+ user: 'admin',
+ password: ''
+ }
+ })
+ .its('body')
+ .should('equal', '{ "status" : "ok", "message" : "Scan completed! " }')
+ })
+
beforeEach(() => {
cy.visit('')
})
@@ -43,6 +56,10 @@ context('Function Documentation', () => {
.click()
cy.get('.form-inline > .btn')
.should('be.visible')
+ cy.get('[name=appmodules]')
+ .check()
+ cy.get('.form-inline > .btn')
+ .click()
// check module from fundocs itself
cy.get('#modules')
.contains('http://exist-db.org/xquery/docs')