-
Notifications
You must be signed in to change notification settings - Fork 4
Feat/pd 5257 update d3 #2067
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
arimieandreea
wants to merge
45
commits into
feat/PD-5258
Choose a base branch
from
feat/PD-5257-updateD3
base: feat/PD-5258
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Feat/pd 5257 update d3 #2067
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…ct 18 - Update React to v18.2.0 and React DOM to v18.2.0 - Migrate from ReactDOM.render to createRoot API - Install and configure React Testing Library (@testing-library/react, jest-dom, dom) - Update jest.config.js: setupFilesAfterEnv, jsdom environment, transform ES modules - Update babel.config.js: conditional ignore for node_modules in test mode - Add workspace package mapping for @pie-lib/* packages in Jest - Migrate test files from Enzyme to RTL in multiple packages: - config-ui: langs, settings-panel, two-choice, feedback-config, choice-configuration, layout - charting: axes, chart-type, chart, grid, mark-label, bars, histogram, drag-handle, line tests, plot tests - editable-html: characters, css, image, media, respArea, toolbar tests - render-ui: html-and-math, preview-prompt, purpose, readable, response-indicators, ui-layout, collapsible - mask-markup: mask, with-mask, blank, correct-input, dropdown, input - icons, drag, correct-answer-toggle tests - Update test-utils package with RTL helpers and MUI theme providers - Delete obsolete Enzyme snapshots (will be replaced with RTL patterns) - Update package dependencies and yarn.lock
- Add fileMock.js to mock image/asset imports - Add jest-resolver.js to handle node: protocol imports
…ag packages
- Add @testing-library/jest-dom imports to test files
- Fix minHeight style assertion to use string format ('200px')
- Fix UidProvider import to use correct named export (Provider)
- Migrate image plugin tests (component, image-toolbar-logic) - Migrate math plugin tests - Migrate table plugin tests (table-toolbar) - Migrate toolbar plugin tests (default-toolbar, toolbar-buttons, toolbar) - Remove Enzyme snapshot files in drag and editable-html plugins - Replace shallow/mount with RTL render - Update assertions to use RTL queries and matchers
- Replace editor.test.jsx with focused editor-utils.test.js - Refactor editor.jsx for better testability - Update toolbar tests to RTL patterns - Remove Enzyme snapshots
**Jest Upgrade (v24.1.0 → v29.7.0):** - Update jest, babel-jest, @types/jest to v29.7.0 - Add jest-environment-jsdom package (required for Jest 29) - Configure jest-circus runner explicitly in jest.config.js - Add TextEncoder/TextDecoder polyfills for jsdom compatibility **Test Setup Improvements:** - Enable global @testing-library/jest-dom matchers in jest.setup.js - Remove redundant jest-dom imports from 50+ test files across packages: - charting (axes, chart-type, chart, grid, mark-label, bars, histogram, plot, line, drag-handle) - config-ui (langs, number-text-field, settings-panel, two-choice, choice-configuration, feedback, layout, tags-input) - correct-answer-toggle, drag, editable-html, icons, render-ui - Enhance test-utils with keyboard helpers and web component utilities **Benefits:** - Modern Jest features and better error messages - Cleaner test files (no repetitive imports) - Better performance and reliability - Improved compatibility with React 18 and RTL
…sting Library - Migrate all graphing component tests from Enzyme shallow rendering to RTL render - Replace snapshot tests with basic rendering assertions - Remove all Enzyme-based snapshot files - Update test-utils to remove Shadow DOM utilities and add light DOM helpers - Remove: withinShadow, queryInShadow, queryAllInShadow, queryInShadowDOM, hasShadowRoot, getShadowRootMode - Add: isCustomElementDefined, createCustomElement - Enhance scaleMock test utility with domain, range, and copy methods - Mark incomplete legacy Enzyme tests with .skip for future migration Test files migrated: - graph-with-controls, graph, grid, labels, mark-label, toggle-bar, tool-menu, undo-redo - axis: arrow, axes - tools: circle, line, point, polygon, ray, segment, vector - shared: arrow-head, line components, point components This migration improves test maintainability and aligns with modern React testing practices.
…esting Library - Migrate all graphing-solution-set component tests from Enzyme shallow rendering to RTL render - Replace snapshot tests with basic rendering assertions - Remove all Enzyme-based snapshot files - Enhance scaleMock test utility with domain, range, and copy methods - Add missing React import to point component - Mark incomplete component tests with .skip for future migration Test files migrated: - graph-with-controls, graph, grid, labels, mark-label, toggle-bar, tool-menu, undo-redo - axis: arrow, axes - tools: line, polygon - shared: arrow-head, line components, point components This migration improves test maintainability and aligns with modern React testing practices.
- Update test assertions to match actual rendering (styled divs vs semantic tags) - Remove unnecessary renderChildren mocks - Update component props (value -> choice) - Skip tests with @dnd-kit dependency conflicts - Remove snapshot files and update remaining snapshots
- Replace Enzyme shallow rendering with RTL render - Replace snapshot tests with basic rendering assertions - Remove instance-based logic tests - Delete snapshot files
- Skip tests requiring drag-and-drop context setup - Add missing props to axis tests (columnTicksValues, rowTickValues, skipValues, dy) - Enhance customScaleMock with domain, range, and copy methods
- Replace Enzyme mount with RTL render - Replace wrapper.instance() with container.querySelector() - Update snapshots for HTML attribute quotes - Apply to both math-rendering and math-rendering-accessible packages
- Replace Enzyme shallow rendering with RTL render - Replace snapshot tests with basic rendering assertions - Remove instance-based logic tests in favor of user-facing behavior tests - Delete all snapshot files - Test files updated: text-select, token-select, tokenizer
- Replace Enzyme shallow rendering with RTL render - Replace snapshot tests with basic rendering assertions - Delete all snapshot files
- Replace Enzyme shallow rendering with RTL render - Replace snapshot tests with basic rendering assertions - Remove instance-based logic tests - Delete snapshot files
- Add tests for position state reset in Draggable component - Add grid calculation tests for gridDraggable HOC - Add drag handler tests (onStart, onDrag, onStop) - Add boundary and snap behavior tests - Improve mock setup for DraggableCore to enable handler testing
- Replace Enzyme shallow/mount with RTL render - Add proper mocks for dependencies (@pie-lib/editable-html, @pie-lib/config-ui, @hello-pangea/dnd) - Replace snapshot tests with semantic queries - Add MUI ThemeProvider for proper component rendering - Delete snapshot file
- Replace react-test-renderer with RTL render - Add comprehensive rendering and interaction tests - Add MUI ThemeProvider for proper component rendering - Test checkbox behavior and onChange callbacks - Delete snapshot file chore(jest): update Jest configuration - Remove explicit testRunner config (Jest 29 default) - Enable console error/warning suppression in tests - Filter out React warnings to reduce noise
- Replace Enzyme shallow rendering with RTL render - Replace snapshot tests with basic rendering assertions - Fix rotatable component unmount bug in tests - Delete all snapshot files Test files migrated: - rotatable - protractor: graphic, index - ruler: graphic, index, unit-type, unit
… into feat/PD-5257-tests merge remote into current.
merge parent into current.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.