Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
fontane-notizbuecher
SADE
Commits
150e37ef
Commit
150e37ef
authored
Aug 26, 2018
by
Mathias Goebel
Browse files
implement unit tests stage
parent
5b3b3942
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
.gitlab-ci.yml
View file @
150e37ef
image
:
frekele/ant
image
:
docker.gitlab.gwdg.de/fontane-notizbuecher/build:latest
variables
:
EXIST-DB
:
"
eXist-db-4.3.1"
stages
:
-
build
-
test
-
deploy
ant
:
...
...
@@ -12,6 +16,23 @@ ant:
paths
:
-
build/*.xar
installation
:
stage
:
test
script
:
-
wget --quite --output-document=${EXIST-DB}.tar.gz https://bintray.com/existdb/releases/download_file?file_path=${EXIST-DB}.tar.gz
-
tar -xzf ${EXIST-DB}.tar.gz
-
cp build/*.xar ${EXIST-DB}/autodeploy
-
bash ${EXIST-DB}/bin/startup.sh | tee output.log &
# wait for eXist
-
while [ $(curl -I -s http://localhost:8080 | grep -c "200 OK") == 0 ]; do sleep 2s; done
# shutdown eXist
-
bash ${EXIST-DB}/bin/shutdown.sh
-
mv /tmp/tests-*.xml .
artifacts
:
paths
:
-
output.log
-
tests-*.xml
upload
:
stage
:
deploy
script
:
...
...
build.xml
View file @
150e37ef
...
...
@@ -5,7 +5,6 @@
<property
name=
"build.dir"
value=
"build"
/>
<target
name=
"xar"
>
<copy
file=
"expath-pkg.xml.tmpl"
tofile=
"expath-pkg.xml"
filtering=
"true"
overwrite=
"true"
>
<filterset>
<filter
token=
"project.version"
value=
"${project.version}"
/>
...
...
post-install.xq
View file @
150e37ef
xquery
version
"3.1"
;
exrest:register-module
(
xs:anyURI
(
"/db/apps/SADE/modules/fontane/index-api.xqm"
))
,
exrest:register-module
(
xs:anyURI
(
"/db/apps/SADE/modules/fontane/toc-api.xqm"
))
exrest:register-module
(
xs:anyURI
(
"/db/apps/SADE/modules/fontane/toc-api.xqm"
))
,
let
$doc
:=
doc
(
"expath-pkg.xml"
)
//*:
package
,
$app
:=
string
(
$doc
/
@abbrev
)
,
$version
:=
string
(
$doc
/
@version
)
,
$filename
:=
string-join
((
"/tmp/tests"
,
$app
,
$version
)
,
"-"
)
||
".xml"
return
<tests
application=
"
{
$app
}
"
version=
"
{
$version
}
"
>
{
util:eval
(
"modules/fontane/tests.xq"
)}
</tests>
=>
file:serialize
(
$filename
,
())
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment