Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Register
  • Sign in
  • Dia Dia
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 410
    • Issues 410
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 13
    • Merge requests 13
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • GNOMEGNOME
  • DiaDia
  • Issues
  • #6
Closed
Open
Issue created Jun 03, 2018 by Tomáš Pospíšek@tpoContributor

[Patch] test doesn't use the correct paths

When building the dia package under Debian, Debian's dh_auto_test will run among other things make check-local in each subdirectory of dia's source code distribution.

In particular this will execute make check-local inside the tests subdirectory, where this will run the test target:

$ cat tests/Makefile.am
[...]
# rum make test as part of make check
check-local: test
[...]

The test target:

  • will run dia
  • will lint a shape file (as far as I understand)
  • and will run the objects test
$ cat tests/Makefile.am
[...]
test: $(TEST_PROGS)
        ../app/run_dia.sh $(top_srcdir)/samples/render-test.dia --export=rt.shape && \
        xmllint --dtdvalid $(top_srcdir)/doc/shape.dtd rt.shape && rm rt.shape && rm rt.png
        ./objects ../objects//
[...]

The problem here is, while the run_dia.sh script will correctly set component paths via environment variables (that is DIA_SHAPE_PATH, DIA_LINE_PATH et al. - see #5 for a request and patch to document these variables), the objects script does not set those paths correctly. The result is, that the objects test will run its test with components from the default dia paths which is /usr/share/dia on my system here. If that path contains components that fail the tests - such as the shape files installed by Debian's dia-shapes package - then the objects test will fail.

This is the case under Debian, and that is why the Debian build dependencies contain an explicitly declared conflict with the dia-package:

$ cat debian/control
[...]
Build-Conflicts: autoconf2.13,
       dia-shapes
[...]

It would be better though if dia's tests during the build would run against the contents of it's own source code distribution exclusively and not against any locally installed, potentially buggy components. Also running the tests against any external components makes the test non-idempotent (aka on a clean system the build will not find anything under /usr/share/dia, however after make install /usr/share/dia will be populated.

Edited Jun 03, 2018 by Tomáš Pospíšek
Assignee
Assign to
Time tracking