Closed imanjra closed 4 months ago
This update enhances the operator prompt interface by adding new data attributes for testing, introducing new control variables in utility functions, and updating end-to-end test scripts. It also includes new classes and configurations for E2E tests, enabling more robust and detailed testing of prompt dialogs and drawers in the operators' browser interface.
Files/Paths | Change Summaries |
---|---|
app/packages/operators/src/OperatorPrompt/OperatorDrawerPrompt.tsx |
Added a Box component with data-cy attribute around OperatorPromptBody . |
app/packages/operators/src/OperatorPrompt/OperatorModalPrompt.tsx |
Introduced dialogProps with PaperProps containing data-cy attribute. |
app/packages/operators/src/utils.ts |
Added new variables (loading , disableSubmit , disabledReason , and onClose ) to getOperatorPromptConfigs . |
e2e-pw/src/oss/poms/operators/operators-prompt.ts |
Introduced OperatorsPromptPom class with methods for prompt interactions and OperatorsPromptAsserter for assertions. |
e2e-pw/src/oss/specs/operators/built-in-operators.spec.ts |
Removed HistogramPom import and histogramPanel declaration. |
e2e-pw/src/oss/specs/operators/prompt.spec.ts |
Added test cases for interacting with prompt dialogs and drawers, including canceling, executing actions, and checking progress indicators. |
e2e-pw/src/shared/assets/plugins/e2e/__init__.py |
Introduced classes E2ESayHelloInModal , E2ESayHelloInDrawer , and E2EProgress for E2E tests, with methods for input resolution, execution, and output resolution. |
e2e-pw/src/shared/assets/plugins/e2e/fiftyone.yml |
Expanded functionality to include new operators for E2E tests: e2e_say_hello_in_modal , e2e_say_hello_in_drawer , and e2e_progress . |
sequenceDiagram
participant User
participant OperatorsPromptPom
participant OperatorsBrowserPom
participant E2EProgress
User->>OperatorsBrowserPom: Initiate Prompt
OperatorsBrowserPom->>OperatorsPromptPom: Open Modal/Drawer
OperatorsPromptPom->>E2EProgress: Execute Action
E2EProgress-->>OperatorsPromptPom: Return Progress
OperatorsPromptPom-->>OperatorsBrowserPom: Display Progress
User-->>OperatorsPromptPom: Interact with Prompt
OperatorsPromptPom-->>User: Provide Feedback
In the land of code so bright, Prompts now shine with testing light, Modals, drawers, all in view, Operators' tasks are clear and true. With progress bars and actions neat, Our tests ensure the code's complete.
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
What changes are proposed in this pull request?
fix operator prompt hidden for executing, output, and error stages of operator execution
How is this patch tested? If it is not, please explain why.
Manually in the app and E2E
Release Notes
Is this a user-facing change that should be mentioned in the release notes?
Fixed issue where operator prompt is now shown for executing, output, and error stages of operator execution
What areas of FiftyOne does this PR affect?
fiftyone
Python library changesSummary by CodeRabbit
New Features
e2e_say_hello_in_modal
,e2e_say_hello_in_drawer
, ande2e_progress
.Improvements
Bug Fixes