Skip to content

test: add integration tests for chat history feature#8874

Merged
ugur-vaadin merged 5 commits intomainfrom
test-add-integration-tests-for-chat-history-feature
Mar 19, 2026
Merged

test: add integration tests for chat history feature#8874
ugur-vaadin merged 5 commits intomainfrom
test-add-integration-tests-for-chat-history-feature

Conversation

@ugur-vaadin
Copy link
Copy Markdown
Contributor

Description

Adds integration tests for the AI Orchestrator chat history support.

No related issue.

Type of change

  • Bugfix
  • Feature
  • Test

Checklist

  • I have read the contribution guide: https://vaadin.com/docs/latest/contributing/overview
  • I have added a description following the guideline.
  • The issue is created in the corresponding repository and I have referenced it.
  • I have added tests to ensure my change is effective and works as intended.
  • New and existing tests are passing locally with my change.
  • I have performed self-review and corrected misspellings.

@ugur-vaadin ugur-vaadin requested a review from tomivirkki March 9, 2026 10:37
var savedHistory = (List<ChatMessage>) VaadinSession.getCurrent()
.getAttribute(HISTORY_SESSION_KEY);
if (savedHistory != null) {
builder.withHistory(savedHistory, Collections.emptyMap());
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Instead of Collections.emptyMap() (= not restoring attachments with the history), also store the attachmentStorage to VaadinSession so they get restored on refresh

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Updated to restore attachments on refresh.

@ugur-vaadin ugur-vaadin enabled auto-merge (squash) March 19, 2026 10:36
@sonarqubecloud
Copy link
Copy Markdown

@ugur-vaadin ugur-vaadin merged commit c289c2e into main Mar 19, 2026
6 checks passed
@ugur-vaadin ugur-vaadin deleted the test-add-integration-tests-for-chat-history-feature branch March 19, 2026 11:35
vaadin-bot pushed a commit that referenced this pull request Mar 19, 2026
* test: add integration tests for chat history feature

* test: update test to use refresh to mimic real use and move test

* test: restore attachments on refresh
DiegoCardoso pushed a commit that referenced this pull request Mar 19, 2026
* test: add integration tests for chat history feature

* test: update test to use refresh to mimic real use and move test

* test: restore attachments on refresh

Co-authored-by: Ugur Saglam <106508695+ugur-vaadin@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants