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

Chore update storybook & Webpack & Cypress #1589

Merged
merged 53 commits into from
May 23, 2023
Merged

Conversation

pointhalo
Copy link
Collaborator

@pointhalo pointhalo commented May 5, 2023

中文模板 / Chinese Template

What kind of change does this PR introduce? (check at least one)

  • Bugfix
  • Feature
  • Code style update
  • Refactor
  • Test Case
  • TypeScript definition update
  • Document improve
  • CI/CD improve
  • Branch sync
  • Other, please describe:

PR description

  1. 升级 storybook版本,原低版本 storybook 基于 webpack4,现根目录 webpack锁定v5后,storybook无法跑起、导致 e2e cyprss 也无法运行
  1. 升级 babel相关依赖版本
  2. 升级 ci 相关镜像 node 版本
  3. 解决升级后更严格的ts类型检查报错问题
  4. Node 版本升级,cypress版本需要跟随升级,相关 e2e 用例有些无法兼容需要改写

Checklist

  • Test or no need
  • Document or no need
  • Changelog or no need

Other

  • Skip Changelog

Additional information

@pointhalo
Copy link
Collaborator Author

#1580
目标分支应为main 更合理,这里重新提交一个PR

@codesandbox-ci
Copy link

codesandbox-ci bot commented May 5, 2023

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 4292d34:

Sandbox Source
DouyinFE/semi-design Configuration
Semi Design: Simple Story Configuration

@pointhalo
Copy link
Collaborator Author

pointhalo commented May 6, 2023

@pointhalo
Copy link
Collaborator Author

pointhalo commented May 22, 2023

在更新 Cypress 镜像后(Cypress版本应不同),当前版本 Cypress Test Case 存在的问题:

  • Tabs、Radio、AutoComplete、Checkbox、Tag
    依赖 cy.get('body').tab cypress-plugin-tab 提供的功能,似乎与新版本 cypress 不能一起工作
    image

  • ✅ Anchor

    • 使用 cy.get('root')改为 cy.root()
    • 最后一个 test case没有做任何 assert ,改正,补充
  • OverflowList

    • resize case:对slider 的mouseDown、mouseUp 操作未起作用。是否与 Slider v2.35的修改相关?
  • ✅ cascader

    • 使用 cy.get('root'),改为 cy.root() 即可
  • ✅Timepicker

    • 使用 cy.get('root'),改为 cy.root() 即可
    • custom trigger 没有 assert,改正,补充
  • Slider

    • get[data-cy=xxx] 的方式获取 dom 有误

@pointhalo pointhalo changed the title [WIP] Chore update storybook [WIP] Chore update storybook & Webpack & Cypress May 23, 2023
@pointhalo
Copy link
Collaborator Author

由于 cypress-plugin-tab 暂时无法与> v10 的cypress 兼容,所以使用 cypress-real-event代替。
大部分场景可平移,但仍存在少部分无法兼容的case:例如 body 直接按tab聚焦、tab+shift 组合键使用

有部分测试用例由于 tab 事件的限制 或 用例本身不确定性,暂时在 chore-updateStorybook 分支注释掉,避免阻塞整个流程。
后续需要人工介入check一下,是否改写,或者依旧先以注释方式先跳过。

@pointhalo pointhalo changed the title [WIP] Chore update storybook & Webpack & Cypress Chore update storybook & Webpack & Cypress May 23, 2023
@pointhalo
Copy link
Collaborator Author

Typography 的 Test Case 有概率性失败. test:cypress 任务成功, test-coverage 任务失败
image

@pointhalo pointhalo merged commit fd9f597 into main May 23, 2023
@pointhalo pointhalo deleted the chore-updateStorybook branch May 23, 2023 12:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants