Praman — AI-First SAP UI5 Test Automation Platform - v1.0.1
    Preparing search index...

    Function assertField

    • Resolves a field label via vocabulary, reads the control's text, and compares it.

      Parameters

      • ui5: UI5HandlerSlice

        UI5 interaction handler.

      • vocabulary: VocabLookup

        Vocabulary lookup service.

      • label: string

        Human-readable field label (e.g. 'Status').

      • expected: string

        Expected text value.

      Returns Promise<IntentResult<void>>

      An IntentResult<void> describing the outcome. status is 'error' when the term is not found or the value does not match.

      Assert a field value by business label without knowing the control ID.

      Enables readable, maintainable assertions in E2E tests.

      import { assertField } from '#intents/core-wrappers.js';

      const result = await assertField(ui5, vocab, 'Status', 'In Process');
      expect(result.status).toBe('success');