Przejdź do treści
Biblioteka skilli
Programowanie · Testowanie

edt-mcp-build-test

/edt-mcp-build-test

Pokazuje, jak zbudować wtyczkę Eclipse EDT-MCP przez Tycho i Maven, uruchomić testy jednostkowe i e2e oraz zasady testów w repozytorium.

Licencja
AGPL-3.0
Ostatnia zmiana repozytorium
12.11.2026

Ocena i bezpieczeństwo

100/ 100Klasa: dobry
Format25 / 25
Frontmatter z nazwą i opisem, poprawna nazwa, opis do 1024 znaków, nazwa zgodna z folderem.
Odkrywalność25 / 25
Opis mówi, kiedy użyć skilla, ma sensowną długość i jest w 3. osobie.
Treść35 / 35
Co najmniej 150 słów i do 500 linii, nagłówki, listy kroków, przykłady albo kod.
Higiena15 / 15
Bez zaślepek typu TODO, bez ścieżek Windows, z licencją.
Ryzykobrak sygnałów w skanie
Pliki w paczce
1
Skrypty
0
Komentarze HTML
0
Adresy URL w SKILL.md
1
Przestarzałość

Brak sygnałów. Repozytorium zmienione 12.11.2026, bez odwołań do wycofanych modeli i API.

Licencja

AGPL-3.0, copyleft: przeróbki udostępniane innym muszą mieć tę samą licencję.

Co robi i kiedy

Pokazuje, jak zbudować wtyczkę Eclipse EDT-MCP przez Tycho i Maven, uruchomić testy jednostkowe i e2e oraz zasady testów w repozytorium.

Oryginalny opis (EN)

How to build the EDT-MCP Eclipse plugin (Tycho/Maven) and run its unit and e2e tests, plus the test conventions for this repo. Use when building the plugin, running or writing tests, or verifying a change before committing.

Jak działa

  1. Layout
  2. Build
  3. Live redeploy (Tier 2 — the only proof of runtime behaviour)
  4. Unit tests — conventions
  5. Coverage gate
  6. E2E
  7. Protocol conformance
  8. Before committing
Sekcje z nagłówków SKILL.md, w oryginale · 64 linii, 888 słów
Podgląd SKILL.md
---
name: edt-mcp-build-test
description: How to build the EDT-MCP Eclipse plugin (Tycho/Maven) and run its unit and e2e tests, plus the test conventions for this repo. Use when building the plugin, running or writing tests, or verifying a change before committing.
---

# EDT-MCP — build and tests

## Layout

- Maven/Tycho reactor: `mcp/` (bom, bundles, features, repositories, targets, tests).
- Unit tests: `mcp/tests/com.ditrix.edt.mcp.server.tests/src` (JUnit4, a plug-in fragment).
- Stdio runtime: generated during `process-classes` from the live registrar/schemas, compiled for Java 17 and embedded in the plugin; packaging tests verify the shipped artifact.
- E2E: `tests/e2e/run_all.py` + `tools/test_<tool>.py` (Python; runs the MCP server against `TestConfiguration/`).

## Build

A Tycho build from `mcp/` (Maven, JDK 25 - Tycho 5 needs 21+ and the EDT 2026.2 platform is Java 25; the bundle itself still compiles to release 17). The artifact is a p2 update-site in `repositories/com.ditrix.edt.mcp.server.repository/target`.

**A local build is available — use it to validate Java edits** (don't claim "verified by review/grep only"). The canonical script is `source/compile.sh` (it reproduces the CI flow `mvn clean verify -T 1C` from `.github/workflows/build.yml`):

```bash
# from the repo root: compile + unit tests
bash source/compile.sh
# compile only (no Surefire) — faster
bash source/compile.sh --skip-tests
```

- The toolchain (JDK 25 + Maven 3.9+) is often **not on `PATH`** — pass it explicitly: `--java-home <JDK25 home> --maven-home <maven home>` (or env `JAVA_HOME`/`MAVEN_HOME`). The exact paths are **machine-specific — discover them on the spot**, don't hardcode into committed files. Exact options are in README "Building from source".
- **The first build is slow**: Tycho pulls the EDT p2 repository (`edt.1c.ru`) + the Eclipse SDK (hundreds of MB). Once the caches are warm (`~/.m2/repository/p2`, `.cache/tycho`) it runs in ~1 minute. If the caches are absent and there's no network, the build legitimately can't run — say so, don't fake "green".
- **Unit tests need the target platform too** (Mockito/JUnit come from the p2 target, not plain Maven Central) — a green `compile.sh` is the real proof for Java edits; grep only catches anchor/text problems.
- When sharing a local Tycho cache, hold the shared build lock for the entire Maven process. With a warm cache, `mvn -o clean verify --batch-mode -T 1` is the offline equivalent; run the full suite without `-Dtest` before handoff. Discover toolchain/cache/lock paths locally.

## Live redeploy (Tier 2 — the only proof of runtime behaviour)

A green build proves Java logic; only a redeploy proves a tool's schema, description, response and behaviour. The loop itself (owned EDT stand, exact component deployment, bundle hash/origin check and scoped restart) is in `edt-mcp-testing` and `edt-mcp-ready-to-deploy`. The traps that belong to the build:

- **Redeploy without a `-Build` flag only swaps the LAST built jar** — run `compile.sh` first (or pass `-Build`), else you ship stale code and validate the previous build.
- **Stop only the owned stand before deployment**: verify recorded PID, executable, workspace, port and active operations; stop only that process and verified task-owned descendants. Never terminate by image name. Preserve unrelated EDT and 1C sessions; clean up the task's own temporary launches when checks finish.
- **Inspect payloads with `Invoke-RestMethod`** (PowerShell), not `curl` — curl mangles nested JSON. Tools with a JSON responseType put the data in `result.structuredContent`; `content[0].text` is only a `Done`/`Error` placeholder. **Do the handshake first**: the server validates its session, so a cold `tools/call` answers `400` — send `initialize`, keep the `Mcp-Session-Id` it returns and put that header on every later request (the e2e harness client does this for you).
- **Infobase-dependent tools** (debug / run / YAXUnit / profiling) need the infobase (or a `launch`) started first.

## Unit tests — conventions

- One `XxxToolTest` per tool (`tools/impl/`), JUnit4.
- Base pattern: `tool.execute(params)` + a sentinel-message check (e.g. "Project not found") for argument validation. Reference: `WriteModuleSourceToolTest`.
- **Bilingual invariant**: for tools that resolve metadata/code, a case with a Russian identifier/synonym (reference `WriteModuleSourceToolTest.testResolveRussianObjectName`). See skill `edt-mcp-bilingual`.

## Coverage gate

`BuiltInToolTestCoverageTest` (unit) fails the build if a registered tool has no `XxxToolTest`; the e2e coverage ratchet (`tools/test_coverage_ratchet.py`) fails the suite if a `tools/list` tool has no `test_<tool>.py`. Adding a tool without a test fails the build.

## E2E

`tests/e2e/run_all.py` (+ `tools/test_<tool>.py`, one per tool) runs scenarios against the live server and `TestConfiguration/` with git-fixture isolation. The round-trip of Cyrillic synonyms and the synonym-keyed-by-language-code check live in `test_create_metadata.py` / `test_get_metadata_details.py`. A new tool — add `tools/test_<tool>.py`. Full guide: `edt-mcp-e2e-testing` (and `tests/e2e/SKILL.md`).

## Protocol conformance

The focused `tests/e2e/stdio_transport.py` runner attaches two bootstrap processes to the live EDT used by HTTP e2e. Set explicit `EDT_MCP_EDT_INSTALL`, `EDT_MCP_EDT_WORKSPACE` and `JAVA_HOME`; it discovers the shipped jar through the private registry and uses `java -jar`, including on Linux CI. It verifies real calls, live catalog parity, UTF-8, per-client capabilities and EDT survival after EOF, reusing the harness's output-schema validation. It does not exercise Windows cold startup; verify that with the real client on the stand.

A separate gate from the e2e business-logic suite: the official `modelcontextprotocol/conformance` suite validates the SERVER against the MCP wire spec (handshake, capabilities, session-id, `isError`, `ping`, SSE). Lives in `tests/conformance/` (`baseline.yml` pins the intentional gaps; `README.md` explains the layer split). Run: `npx @modelcontextprotocol/conformance@latest server --url http://127.0.0.1:8765/mcp --spec-version 2025-11-25 --expected-failures tests/conformance/baseline.yml`.

## Before committing
- [ ] Build passes
- [ ] Unit tests green; a new/changed tool has a test
- [ ] If metadata/code resolution is touched — a bilingual case exists
- [ ] (if applicable) the e2e scenario is updated
- [ ] For a finished piece of work, run the full `edt-mcp-ready-to-deploy` checklist (build → README → live redeploy → golden → full e2e → conformance → clean tree)

Wersje

RepozytoriumWynikLicencja
Ta strona · infostart-hub/edt-mcp-aiadopted100AGPL-3.0
ditrixnew/edt-mcp100AGPL-3.0

Migawka bazy z 13.11.2026 · wersja paczki 0390fa7e9f98 (skrót SHA-256 całej paczki)

Pobrania w ostatnich 30 dniach: 1 · ranking

Zgłoś problem z tym skillem: szkodliwa treść, błędny opis albo prośba autora o usunięcie.

Podobne skille

  • 100edt-mcp-yaxunit
    Pomaga pisać i uruchamiać testy jednostkowe YAXUnit dla konfiguracji 1C przez 1C:EDT i narzędzia EDT-MCP, z modułami ИсполняемыеСценарии i asercjami ЮТест.
  • 90edt-mcp-testing
    Opisuje, jak testować ręcznie każde narzędzie serwera EDT-MCP w działającym środowisku EDT, z przykładowym wywołaniem i oczekiwanym wynikiem.
  • 88edt-mcp-testing
    Testuje ręcznie od początku do końca każde narzędzie serwera EDT-MCP na żywym środowisku EDT, z oczekiwanym wynikiem i pułapkami.
  • 100edt-mcp-e2e-testing
    Opisuje, jak pisać i uruchamiać zautomatyzowany zestaw testów black-box e2e, który obejmuje każde narzędzie EDT-MCP na żywym serwerze.
  • 90eclipse-edit
    Edytuje pliki w projektach Eclipse przez narzędzia MCP, utrzymując zgodność edytorów, kompilację przyrostową i cofanie przez lokalną historię.
  • 100eclipse
    Wspiera pracę w Eclipse IDE: programowanie w Javie (JDT), wtyczki m2e dla Mavena i Gradle, konfiguracja workspace i debugowanie aplikacji enterprise.

Uwagi i zgłoszenia

Wiadomość trafi do Bartosza Sokolińskiego. Adres e-mail jest potrzebny tylko do odpowiedzi. Szczegóły w polityce prywatności.