Skip to content

Commit

Permalink
Merge pull request #1981 from Agenta-AI/test-single-model-scores-modify
Browse files Browse the repository at this point in the history
Test: modify single model evaluation scores
  • Loading branch information
aakrem authored Aug 14, 2024
2 parents 9531a8c + c713da0 commit 8eb5d67
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 1 deletion.
15 changes: 15 additions & 0 deletions agenta-web/cypress/e2e/single-model-test-evaluation.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,21 @@ describe("Single Model Test workflow", () => {

cy.wait("@generateRequest")
cy.get('[data-cy="evaluation-vote-panel-numeric-vote-input"]').type("100")
cy.wait(1000)
cy.get('[data-cy="evaluation-vote-panel-numeric-vote-input"]').should(
"have.value",
"100",
)
})

it("Should modify the evaluation vote scores", () => {
cy.visit(`/apps/${app_id}/annotations/single_model_test`)
cy.url().should("include", "/annotations/single_model_test")
cy.wait(1000)
cy.clickLinkAndWait('[data-cy="single-model-view-evaluation-button"]')
cy.get('[data-cy="evalInstructionsShown-ok-btn"]').click()
cy.get('[data-cy="evaluation-vote-panel-numeric-vote-input"]').clear()
cy.get('[data-cy="evaluation-vote-panel-numeric-vote-input"]').type("85")
})
})

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,11 @@ export default function AutomaticEvaluationResult({
}
return (
<div className="hover-button-wrapper">
<Button type="primary" onClick={() => onCompleteEvaluation(record)}>
<Button
type="primary"
data-cy="single-model-view-evaluation-button"
onClick={() => onCompleteEvaluation(record)}
>
{actionText}
</Button>
</div>
Expand Down

0 comments on commit 8eb5d67

Please sign in to comment.