Skip to content
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

test: RTL overhaul - hackathon #16626

Merged
merged 13 commits into from
Sep 22, 2021
Merged

Conversation

lyndsiWilliams
Copy link
Member

@lyndsiWilliams lyndsiWilliams commented Sep 7, 2021

SUMMARY

Migrate Enzyme test files to React Testing library/Typescript and improve test case quality. See the project description doc for more details.

TESTING INSTRUCTIONS

Migrate to the following files and observe the tests converted to RTL/TS:

  • superset-frontend/spec/javascripts/components/CachedLabel_spec.tsx
  • superset-frontend/spec/javascripts/components/ColumnTypeLabel_spec.tsx
  • superset-frontend/spec/javascripts/dashboard/components/MissingChart_spec.tsx
  • superset-frontend/spec/javascripts/dashboard/components/RefreshIntervalModal_spec.tsx
  • superset-frontend/spec/javascripts/dashboard/components/menu/HoverMenu_spec.tsx
  • superset-frontend/spec/javascripts/dashboard/components/resizable/ResizableContainer_spec.tsx
  • superset-frontend/spec/javascripts/dashboard/components/resizable/ResizableHandle_spec.tsx
  • superset-frontend/spec/javascripts/explore/components/AggregateOption_spec.tsx
  • superset-frontend/spec/javascripts/explore/components/CheckboxControl_spec.tsx
  • superset-frontend/spec/javascripts/explore/components/ColorPickerControl_spec.tsx

ADDITIONAL INFORMATION

  • Has associated issue:
  • Required feature flags:
  • Changes UI
  • Includes DB Migration (follow approval process in SIP-59)
    • Migration is atomic, supports rollback & is backwards-compatible
    • Confirm DB migration upgrade and downgrade tested
    • Runtime estimates and downtime expectations provided
  • Introduces new feature or API
  • Removes existing feature or API

@codecov
Copy link

codecov bot commented Sep 16, 2021

Codecov Report

Merging #16626 (ab733e2) into master (e947f8a) will increase coverage by 0.14%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #16626      +/-   ##
==========================================
+ Coverage   76.71%   76.86%   +0.14%     
==========================================
  Files        1002     1004       +2     
  Lines       53801    53970     +169     
  Branches     6858     7374     +516     
==========================================
+ Hits        41276    41482     +206     
+ Misses      12288    12248      -40     
- Partials      237      240       +3     
Flag Coverage Δ
javascript 71.32% <100.00%> (+0.32%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...erset-frontend/src/profile/components/UserInfo.tsx 100.00% <ø> (ø)
...rset-frontend/src/components/CachedLabel/index.tsx 84.61% <100.00%> (ø)
superset-frontend/src/logger/LogUtils.ts 84.00% <0.00%> (-7.31%) ⬇️
...rontend/src/components/Select/DeprecatedSelect.tsx 82.35% <0.00%> (-3.37%) ⬇️
...mponents/nativeFilters/FiltersConfigModal/utils.ts 72.22% <0.00%> (-1.39%) ⬇️
...uperset-frontend/src/components/Menu/MenuRight.tsx 91.22% <0.00%> (-1.23%) ⬇️
...eFilters/FiltersConfigModal/FiltersConfigModal.tsx 94.31% <0.00%> (-1.14%) ⬇️
...perset-frontend/src/dashboard/util/isValidChild.ts 85.71% <0.00%> (-0.96%) ⬇️
...ntend/src/explore/components/ExploreChartPanel.jsx 14.28% <0.00%> (-0.72%) ⬇️
...c/views/CRUD/data/database/DatabaseModal/index.tsx 44.13% <0.00%> (-0.12%) ⬇️
... and 42 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e947f8a...ab733e2. Read the comment docs.

Copy link
Member

@etr2460 etr2460 left a comment

Choose a reason for hiding this comment

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

lgtm, thanks for doing the jsx => tsx conversion here too! I really appreciate the improved test quality here

Copy link
Member

@eschutho eschutho left a comment

Choose a reason for hiding this comment

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

This is great, thank you!

@eschutho eschutho merged commit 63aadd3 into apache:master Sep 22, 2021
@eschutho eschutho deleted the lyndsi/rtl-overhaul branch September 22, 2021 18:37
opus-42 pushed a commit to opus-42/incubator-superset that referenced this pull request Nov 14, 2021
* CachedLabel_spec fully converted to RTL

* ColumnTypeLabel_spec fully converted to RTL

* MissingChart_spec fully converted to RTL

* RefreshIntervalModal_spec mostly converted to RTL

* HoverMenu_spec mostly converted to RTL

* ResizableContainer_spec fully converted to RTL

* ResizableHandle_spec fully converted to RTL

* AggregateOption_spec fully converted to RTL

* CheckboxControl_spec fully converted to RTL

* ColorPickerControl_spec to RTL

* Finished converting ColorPickerControl_spec to RTL/TS, also converted RefreshIntervalModal_spec to TS

* Added unknown type to ColumnTypeLabelProps

* Fixed ColumnTypeLabel_spec
QAlexBall pushed a commit to QAlexBall/superset that referenced this pull request Dec 28, 2021
* CachedLabel_spec fully converted to RTL

* ColumnTypeLabel_spec fully converted to RTL

* MissingChart_spec fully converted to RTL

* RefreshIntervalModal_spec mostly converted to RTL

* HoverMenu_spec mostly converted to RTL

* ResizableContainer_spec fully converted to RTL

* ResizableHandle_spec fully converted to RTL

* AggregateOption_spec fully converted to RTL

* CheckboxControl_spec fully converted to RTL

* ColorPickerControl_spec to RTL

* Finished converting ColorPickerControl_spec to RTL/TS, also converted RefreshIntervalModal_spec to TS

* Added unknown type to ColumnTypeLabelProps

* Fixed ColumnTypeLabel_spec
@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 1.4.0 labels Mar 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels preset-io size/XL 🚢 1.4.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants