Open mathias-goebel opened 6 years ago
to be able to reproduce.... don't we need config.xqm
and app.xqm
? The test is not self containing.... (as suggested in the issue template)
sure, config is (standard)
declare variable $config:app-root :=
let $rawPath := system:get-module-load-path()
let $modulePath :=
(: strip the xmldb: part :)
if (starts-with($rawPath, "xmldb:exist://")) then
if (starts-with($rawPath, "xmldb:exist://embedded-eXist-server")) then
substring($rawPath, 36)
else
substring($rawPath, 15)
else
$rawPath
return
substring-before($modulePath, "/modules");
app is:
declare function app:currentyear($node as node(), $model as map(*)) {
year-from-date( current-date() )
};
but anyway, no matter whats in config
or app
, as long as the named functions/variables are exposed by the module, %test:stats
will cause this issue here.
ok, clear, thnx for the addition. We'll investigate your report.
@mathias-goebel just to be clear is the problem with 4.0.0 or 4.1-SNAPSHOT?
4.0.0
@mathias-goebel Okay, did you have the problem in 3.6.1?
not checked yet. should i do this?
@mathias-goebel Have you used it in a previous version, and if so what version? I am just trying to understand if this is a regression or not?
sorry, i am just about to setup all unit tests in this application. so there is no previous version where i did the same.
@mathias-goebel okie dokie, we can treat it as a new bug then...
What is the problem
Using XQSuite Unit tests in eXist 4.0.0 with %test:stats causes an NullPointerException. All tests will fail until db restart.
Describe how to reproduce or add a test
returns on first run:
on any later run until restarting eXist:
Context information
Please always add the following information