{"id":19279485,"url":"https://github.com/eeditiones/tei-publisher-lib","last_synced_at":"2026-02-28T08:08:31.425Z","repository":{"id":40494503,"uuid":"266771050","full_name":"eeditiones/tei-publisher-lib","owner":"eeditiones","description":"The core server-side libraries of TEI Publisher, implementing the TEI Processing Model","archived":false,"fork":false,"pushed_at":"2026-02-01T18:06:21.000Z","size":277,"stargazers_count":7,"open_issues_count":6,"forks_count":7,"subscribers_count":10,"default_branch":"master","last_synced_at":"2026-02-02T02:50:19.858Z","etag":null,"topics":["tei-publisher","tei-xml","xquery"],"latest_commit_sha":null,"homepage":"","language":"XQuery","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/eeditiones.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"github":"eeditiones","custom":"https://www.paypal.com/paypalme/eeditiones"}},"created_at":"2020-05-25T12:16:55.000Z","updated_at":"2026-02-01T18:06:25.000Z","dependencies_parsed_at":"2025-12-15T13:07:15.808Z","dependency_job_id":null,"html_url":"https://github.com/eeditiones/tei-publisher-lib","commit_stats":null,"previous_names":[],"tags_count":31,"template":false,"template_full_name":null,"purl":"pkg:github/eeditiones/tei-publisher-lib","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eeditiones%2Ftei-publisher-lib","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eeditiones%2Ftei-publisher-lib/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eeditiones%2Ftei-publisher-lib/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eeditiones%2Ftei-publisher-lib/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/eeditiones","download_url":"https://codeload.github.com/eeditiones/tei-publisher-lib/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eeditiones%2Ftei-publisher-lib/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29928132,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-27T19:37:42.220Z","status":"online","status_checked_at":"2026-02-28T02:00:07.010Z","response_time":90,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["tei-publisher","tei-xml","xquery"],"created_at":"2024-11-09T21:15:22.994Z","updated_at":"2026-02-28T08:08:31.418Z","avatar_url":"https://github.com/eeditiones.png","language":"XQuery","funding_links":["https://github.com/sponsors/eeditiones","https://www.paypal.com/paypalme/eeditiones"],"categories":[],"sub_categories":[],"readme":"\n![TEI Publisher Logo](icon.png)\n\n# TEI Publisher Libraries\n\nThis repository contains the core server-side library of [TEI Publisher](https://teipublisher.com). It implements the TEI Processing Model and is shared between all versions of TEI Publisher and customizations generated by it.\n\n## License\n\nThis software is licensed under the GPLv3 license. If you need a different license: please contact [us](mailto:mail@existsolutions.com) and we'll find an arrangement.\n\n## Testing\n\nThis repository includes built‑in XQSuite unit tests (XQuery‑level) and optional Bats shell tests for CI and local automation.\n\n### XQSuite (in eXist‑db)\n\nXQSuite is eXist‑db’s native unit testing framework for XQuery. See the [documentation](https://exist-db.org/exist/apps/doc/xqsuite)\n\nIn this repository:\n\n- The XQSuite tests live in `test/ts-*.xqm` files (one module per area), e.g. `ts-css.xqm`, `ts-latex.xqm`, `ts-html.xqm`, ...\n- Each module defines `%test:*` annotated functions that exercise the corresponding library in `content/`.\n- `test/test-runner.xq` collects all `ts-*.xqm` modules and returns a JUnit‑style XML report.\n\nRun XQSuite inside eXist:\n\n- In a browser: open `http://127.0.0.1:8080/exist/rest/db/system/repo/tei-publisher-lib-4.0.3/test/test-runner.xq` (adjust base path as needed). You will get a JUnit XML report.\n- With curl:\n  - `curl -fsS -u admin: -H 'Accept: application/xml' 'http://127.0.0.1:8080/exist/rest/db/system/repo/tei-publisher-lib-4.0.3/test/test-runner.xq'`\n- From eXide: open `test/test-runner.xq` and run it; the result is the same JUnit XML.\n\nNaming scheme:\n\n- Test modules are named `ts-\u003ccomponent\u003e.xqm`, e.g. `ts-fo.xqm`, `ts-tei.xqm`.\n- Their module namespaces follow `http://existsolutions.com/apps/tei-publisher-lib/ts-\u003ccomponent\u003e` so they are easy to map back to the area under test.\n\n### Bats Test Suites (optional, for CI)\n\n- Prerequisites: [Bats](https://bats-core.readthedocs.io/en/stable/) , curl. For the XML/XPath suite, xmllint (libxml2-utils) is required.\n- a running eXist-db container as used by the smoke tests.\n\n- `test/01-smoke.bats`: Container smoke tests. Verifies the container responds, is healthy, and that the TEI Publisher Library package is deployed without errors. These tests assume a local Docker container named `exist` listening on port `8080`.\n\n- `test/02-xqsuite.bats`: Calls the XQSuite test runner endpoint and parses the JUnit XML with shell tools. It saves the JUnit report returned by the first endpoint check to `build/testsuite.xml` for inspection/artifacts. Fails the job if any testcase fails.\n\n### Environment\n\nThe HTTP tests can be configured via environment variables (defaults shown):\n\n- `APP_BASE`: Base URL to the deployed library app, e.g. `http://127.0.0.1:8080/exist/rest/db/system/repo/tei-publisher-lib-4.0.3`\n- `RUNNER_PATH`: Path to the XQSuite runner module, default `/test/test-runner.xq`\n- `CREDENTIALS`: Basic auth credentials in the form `user:password`, default `admin:`\n\n### Running\n\n- Run a specific suite: `bats test/02-xqsuite.bats`\n- Run all tests: `bats test/*.bats`\n\nOn success, the XQSuite tests print a header like:\n\n```\n# XQSuite JUnit: tests=… failures=… errors=… pending=… time=… at …\n# Testcases:\n#  - some-test-name: ok\n#  - another-test: FAIL — message type text\n```\n\nThe `02-xqsuite.bats` suite writes the last XML report to `build/testsuite.xml` for diagnostics or CI artifacts.\n\n### Continuous Integration\n\nGitHub Actions (`.github/workflows/build.yml`) runs the Bats suites in CI. The shell tests are optional for local development—you can run the XQSuite directly in eXist as shown above. On CI  `build/testsuite.xml` can is uploaded as an artifact for easier debugging of failures.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feeditiones%2Ftei-publisher-lib","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feeditiones%2Ftei-publisher-lib","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feeditiones%2Ftei-publisher-lib/lists"}