basex test test.xqm => XPDY002c
Friday, 22 October 2021 · 4 messages · last reply 23 Oct 2021
JR
Jonathan Robie22 Oct 2021 23:37 #
I get this error with either the test.xqm found in the BaseX GitHub repo or a copy of the file taken from the web page:
% basex test test.xqm
Stopped at /Users/jonathan/github/basex/basex-core/src/test/resources/, 1/5: [XPDY0002] test: Context is undeclared.
What am I doing wrong?
Jonathan
BD
Bridger Dyson-Smith22 Oct 2021 23:59 #
Hi Jonathan -
I needed to launch the command line basex; e.g.
bridger@ditrestle|~/src/basex-src on master!
± basex
BaseX 9.6.2 [Standalone]
Try 'help' to get more information.
Quoted text · Jonathan Robie · 1 line
> TEST basex-core/src/test/resources/test.xqm
<testsuites time="PT0.988S">
<testsuite
name="file:///usr/home/bridger/src/basex-src/basex-core/src/test/resources/test.xqm"
time="PT0.914S" tests="8" failures="4" errors="1" skipped="1">
<testcase name="assert-success" time="PT0.019S"/>
<testcase name="assert-failure" time="PT0.01S">
<failure line="30" column="14">
<info>Empty sequence.</info>
</failure>
</testcase>
<testcase name="assert-equals-failure" time="PT0.012S">
<failure line="35" column="21">
<returned item="1" type="xs:integer">9</returned>
<expected item="1" type="xs:integer">6</expected>
<info>Item 1: 6 expected, 9 returned.</info>
</failure>
</testcase>
<testcase name="unexpected-success" time="PT0.011S">
<failure>
<expected>err:FORG0001</expected>
</failure>
</testcase>
<testcase name="expected-failure" time="PT0.007S"/>
<testcase name="failure" time="PT0.006S">
<failure line="50" column="12">
<info>Failure!</info>
</failure>
</testcase>
<testcase name="error" time="PT0.006S">
<error line="55" column="6" type="FORG0001">
<info>Cannot convert to xs:double: .</info>
</error>
</testcase>
<testcase name="skipped" skipped="Skipped!" time="PT0S"/>
</testsuite>
</testsuites>
Result: 8 tests, 4 failures, 1 error, 1 skipped.Quoted text · Jonathan Robie · 14 lines
On Fri, Oct 22, 2021 at 3:37 PM Jonathan Robie <jonathan.robie at gmail.com> wrote: > I get this error with either the test.xqm found in the BaseX GitHub repo > or a copy of the file taken from the web page: > > % basex test test.xqm > Stopped at /Users/jonathan/github/basex/basex-core/src/test/resources/, > 1/5: > [XPDY0002] test: Context is undeclared. > > What am I doing wrong? > > Jonathan >
BD
Bridger Dyson-Smith23 Oct 2021 00:02 #
Jonathan - apologies for the truncated email.
This also works for me:
bridger@ditrestle|~/src/basex-src on master!
± basex -t basex-core/src/test/resources/test.xqm
<testsuites time="PT0.975S">
<testsuite
name="file:///usr/home/bridger/src/basex-src/basex-core/src/test/resources/test.xqm"
time="PT0.892S" tests="8" failures="4" errors="1" skipped="1">
<testcase name="assert-success" time="PT0.014S"/>
<testcase name="assert-failure" time="PT0.011S">
<failure line="30" column="14">
<info>Empty sequence.</info>
</failure>
</testcase>
...etc...e.g. using the
-t flag on the basex command.
I hope that's helpful.
Best,
BridgerQuoted text · Bridger Dyson-Smith · 66 lines
On Fri, Oct 22, 2021 at 4:00 PM Bridger Dyson-Smith <bdysonsmith at gmail.com> wrote: > Hi Jonathan - > > I needed to launch the command line basex; e.g. > bridger@ditrestle|~/src/basex-src on master! > ± basex > BaseX 9.6.2 [Standalone] > Try 'help' to get more information. > > TEST basex-core/src/test/resources/test.xqm > <testsuites time="PT0.988S"> > <testsuite > name="file:///usr/home/bridger/src/basex-src/basex-core/src/test/resources/test.xqm" > time="PT0.914S" tests="8" failures="4" errors="1" skipped="1"> > <testcase name="assert-success" time="PT0.019S"/> > <testcase name="assert-failure" time="PT0.01S"> > <failure line="30" column="14"> > <info>Empty sequence.</info> > </failure> > </testcase> > <testcase name="assert-equals-failure" time="PT0.012S"> > <failure line="35" column="21"> > <returned item="1" type="xs:integer">9</returned> > <expected item="1" type="xs:integer">6</expected> > <info>Item 1: 6 expected, 9 returned.</info> > </failure> > </testcase> > <testcase name="unexpected-success" time="PT0.011S"> > <failure> > <expected>err:FORG0001</expected> > </failure> > </testcase> > <testcase name="expected-failure" time="PT0.007S"/> > <testcase name="failure" time="PT0.006S"> > <failure line="50" column="12"> > <info>Failure!</info> > </failure> > </testcase> > <testcase name="error" time="PT0.006S"> > <error line="55" column="6" type="FORG0001"> > <info>Cannot convert to xs:double: .</info> > </error> > </testcase> > <testcase name="skipped" skipped="Skipped!" time="PT0S"/> > </testsuite> > </testsuites> > Result: 8 tests, 4 failures, 1 error, 1 skipped. > > > > On Fri, Oct 22, 2021 at 3:37 PM Jonathan Robie <jonathan.robie at gmail.com> > wrote: > >> I get this error with either the test.xqm found in the BaseX GitHub repo >> or a copy of the file taken from the web page: >> >> % basex test test.xqm >> Stopped at /Users/jonathan/github/basex/basex-core/src/test/resources/, >> 1/5: >> [XPDY0002] test: Context is undeclared. >> >> What am I doing wrong? >> >> Jonathan >> >
JR
Jonathan Robie23 Oct 2021 02:48 #
Excellent, thanks!
Jonathan
Quoted text · Bridger Dyson-Smith · 92 lines
On Fri, Oct 22, 2021 at 4:02 PM Bridger Dyson-Smith <bdysonsmith at gmail.com> wrote: > Jonathan - apologies for the truncated email. > > This also works for me: > bridger@ditrestle|~/src/basex-src on master! > ± basex -t basex-core/src/test/resources/test.xqm > <testsuites time="PT0.975S"> > <testsuite > name="file:///usr/home/bridger/src/basex-src/basex-core/src/test/resources/test.xqm" > time="PT0.892S" tests="8" failures="4" errors="1" skipped="1"> > <testcase name="assert-success" time="PT0.014S"/> > <testcase name="assert-failure" time="PT0.011S"> > <failure line="30" column="14"> > <info>Empty sequence.</info> > </failure> > </testcase> > ...etc... > > e.g. using the `-t` flag on the basex command. > > I hope that's helpful. > Best, > Bridger > > On Fri, Oct 22, 2021 at 4:00 PM Bridger Dyson-Smith <bdysonsmith at gmail.com> > wrote: > >> Hi Jonathan - >> >> I needed to launch the command line basex; e.g. >> bridger@ditrestle|~/src/basex-src on master! >> ± basex >> BaseX 9.6.2 [Standalone] >> Try 'help' to get more information. >> > TEST basex-core/src/test/resources/test.xqm >> <testsuites time="PT0.988S"> >> <testsuite >> name="file:///usr/home/bridger/src/basex-src/basex-core/src/test/resources/test.xqm" >> time="PT0.914S" tests="8" failures="4" errors="1" skipped="1"> >> <testcase name="assert-success" time="PT0.019S"/> >> <testcase name="assert-failure" time="PT0.01S"> >> <failure line="30" column="14"> >> <info>Empty sequence.</info> >> </failure> >> </testcase> >> <testcase name="assert-equals-failure" time="PT0.012S"> >> <failure line="35" column="21"> >> <returned item="1" type="xs:integer">9</returned> >> <expected item="1" type="xs:integer">6</expected> >> <info>Item 1: 6 expected, 9 returned.</info> >> </failure> >> </testcase> >> <testcase name="unexpected-success" time="PT0.011S"> >> <failure> >> <expected>err:FORG0001</expected> >> </failure> >> </testcase> >> <testcase name="expected-failure" time="PT0.007S"/> >> <testcase name="failure" time="PT0.006S"> >> <failure line="50" column="12"> >> <info>Failure!</info> >> </failure> >> </testcase> >> <testcase name="error" time="PT0.006S"> >> <error line="55" column="6" type="FORG0001"> >> <info>Cannot convert to xs:double: .</info> >> </error> >> </testcase> >> <testcase name="skipped" skipped="Skipped!" time="PT0S"/> >> </testsuite> >> </testsuites> >> Result: 8 tests, 4 failures, 1 error, 1 skipped. >> >> >> >> On Fri, Oct 22, 2021 at 3:37 PM Jonathan Robie <jonathan.robie at gmail.com> >> wrote: >> >>> I get this error with either the test.xqm found in the BaseX GitHub repo >>> or a copy of the file taken from the web page: >>> >>> % basex test test.xqm >>> Stopped at /Users/jonathan/github/basex/basex-core/src/test/resources/, >>> 1/5: >>> [XPDY0002] test: Context is undeclared. >>> >>> What am I doing wrong? >>> >>> Jonathan >>> >>
Written for BaseX 9.6. BaseX may have changed since: please check the current documentation.
⚡Generated with XQuery