Skip to content

feat: expose autocomplete scores and add frontend e2e smoke CI#17

Merged
igorsatsyuk merged 8 commits into
mainfrom
feat/score-e2e-smoke-ci
May 10, 2026
Merged

feat: expose autocomplete scores and add frontend e2e smoke CI#17
igorsatsyuk merged 8 commits into
mainfrom
feat/score-e2e-smoke-ci

Conversation

@igorsatsyuk
Copy link
Copy Markdown
Owner

Что сделано\n- �utocomplete-service: AutocompleteQueryService теперь читает Redis ZSET через

everseRangeWithScores и возвращает реальный score в AutocompleteEntry.\n- Обновлены тесты AutocompleteQueryServiceTest и AutocompleteServiceRedisIT (включая строгую JSON-проверку контракта).\n- rontend: добавлена клиентская сортировка подсказок по score (убывание) + unit-тест на порядок.\n- Добавлен постоянный smoke e2e тест rontend/scripts/e2e-smoke.js и команда
pm run test:e2e-smoke.\n- CI: добавлен отдельный job rontend-e2e-smoke (docker compose up +
pm run test:e2e-smoke).\n- Telegram summary: в .github/scripts/compose_telegram_message.py добавлен статус rontend-e2e-smoke.\n- Документация обновлена в README.md и CONTRIBUTING.md.\n\n## Проверки локально\n- mvn -Dtest=AutocompleteQueryServiceTest test (�utocomplete-service)\n- mvn -Dit.test=AutocompleteServiceRedisIT verify (�utocomplete-service)\n-
pm run test:ci -- --include src/app/services/autocomplete.service.spec.ts ( rontend)\n-
pm run test:ci ( rontend)\n-
pm run test:e2e-smoke ( rontend, при поднятом compose)\n\n## Зачем\n- Пробросить score до API-контракта и использовать его на клиенте для детерминированного порядка подсказок.\n- Зафиксировать end-to-end поведение отдельным smoke job в CI и отразить его результат в Telegram уведомлении.

Copilot AI review requested due to automatic review settings May 10, 2026 12:47
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR exposes Redis ZSET scores all the way to the autocomplete API contract, uses those scores on the frontend to enforce deterministic ordering, and adds a Playwright-based frontend E2E smoke test with a dedicated GitHub Actions job and Telegram reporting.

Changes:

  • autocomplete-service: switch to reading ZSET entries via reverseRangeWithScores and return real score values; update unit/integration tests to validate the contract.
  • frontend: client-side sort by score (desc) with a unit test verifying order.
  • CI/docs: add frontend/scripts/e2e-smoke.js, npm run test:e2e-smoke, a new frontend-e2e-smoke workflow job, Telegram summary integration, and documentation updates.

Reviewed changes

Copilot reviewed 11 out of 12 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
README.md Documents the new frontend E2E smoke test and CI job sequence.
CONTRIBUTING.md Adds contributor guidance/checklist updates for running the E2E smoke test.
frontend/src/app/services/autocomplete.service.ts Sorts autocomplete suggestions by descending score on the client.
frontend/src/app/services/autocomplete.service.spec.ts Adds a unit test asserting client-side score sorting.
frontend/scripts/e2e-smoke.js New Playwright E2E smoke script that seeds events and validates UI ordering/click-through.
frontend/package.json Adds test:e2e-smoke script and Playwright dependency.
frontend/package-lock.json Locks Playwright and transitive dependencies.
autocomplete-service/src/main/java/lt/satsyuk/autocomplete/service/AutocompleteQueryService.java Returns actual Redis ZSET scores in AutocompleteEntry.
autocomplete-service/src/test/java/lt/satsyuk/autocomplete/service/AutocompleteQueryServiceTest.java Updates unit test to mock ZSET tuples with scores.
autocomplete-service/src/test/java/lt/satsyuk/autocomplete/integration/AutocompleteServiceRedisIT.java Extends integration tests to assert score and strict JSON contract.
.github/workflows/ci.yml Adds frontend-e2e-smoke job and wires result into Telegram notification.
.github/scripts/compose_telegram_message.py Includes frontend-e2e-smoke in tracked job results and overall status computation.
Files not reviewed (1)
  • frontend/package-lock.json: Language not supported

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread README.md Outdated
Comment thread README.md Outdated
Comment thread frontend/scripts/e2e-smoke.js Outdated
Comment thread frontend/scripts/e2e-smoke.js Outdated
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 12 out of 13 changed files in this pull request and generated 5 comments.

Files not reviewed (1)
  • frontend/package-lock.json: Language not supported

Comment thread frontend/src/app/services/autocomplete.service.ts Outdated
Comment thread frontend/scripts/e2e-smoke.js
Comment thread frontend/scripts/e2e-smoke.js
Comment thread frontend/package.json Outdated
Comment thread .github/workflows/ci.yml
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 12 out of 13 changed files in this pull request and generated 2 comments.

Files not reviewed (1)
  • frontend/package-lock.json: Language not supported

Comment thread frontend/scripts/e2e-smoke.js
Comment thread frontend/scripts/e2e-smoke.js
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 12 out of 13 changed files in this pull request and generated 4 comments.

Files not reviewed (1)
  • frontend/package-lock.json: Language not supported

Comment thread .github/workflows/ci.yml Outdated
Comment thread .github/workflows/ci.yml
Comment thread frontend/src/app/services/autocomplete.service.ts Outdated
Comment thread frontend/package.json Outdated
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 12 out of 13 changed files in this pull request and generated 1 comment.

Files not reviewed (1)
  • frontend/package-lock.json: Language not supported

Comment thread README.md
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 12 out of 13 changed files in this pull request and generated 4 comments.

Files not reviewed (1)
  • frontend/package-lock.json: Language not supported

Comment thread README.md Outdated
Comment thread README.md Outdated
Comment thread CONTRIBUTING.md Outdated
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 12 out of 13 changed files in this pull request and generated no new comments.

Files not reviewed (1)
  • frontend/package-lock.json: Language not supported

@igorsatsyuk igorsatsyuk self-assigned this May 10, 2026
@igorsatsyuk igorsatsyuk merged commit 4dfd89a into main May 10, 2026
19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants