-
-
Notifications
You must be signed in to change notification settings - Fork 3
npm install test 워크플로우 구현 #656
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
Changes from 12 commits
c0d10f8
5225a9c
d10e660
bbae4d8
cde6704
ccab92b
886ad09
b3735b2
1841324
12b1780
a651e05
bfe094d
3c69ba6
d42c88c
2966741
3588eb6
02aa1e6
c4c08bf
3c18eac
e7739f2
51ad6d4
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -19,3 +19,78 @@ | |
| with: | ||
| token: ${{ secrets.CODECOV_TOKEN }} | ||
| - run: bun run build | ||
|
|
||
| install-test: | ||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| include: | ||
| - name: "Create React App (React 18)" | ||
| project: cra | ||
|
|
||
| - name: "Vite + React" | ||
| project: vite | ||
|
|
||
| runs-on: ubuntu-latest | ||
| name: ${{ matrix.name }} | ||
| steps: | ||
| - name: Checkout repository | ||
| uses: actions/checkout@v6 | ||
|
|
||
| - name: Setup Bun | ||
| uses: oven-sh/setup-bun@v2 | ||
| with: | ||
| bun-version: latest | ||
|
|
||
| - name: Install dependencies & Build | ||
| run: | | ||
| bun install | ||
| bun run build:lib | ||
| # ======================================== | ||
| # 테스트 프로젝트 생성 + daleui 설치 | ||
| # ======================================== | ||
|
||
| - name: Create test project & install daleui | ||
| run: | | ||
| mkdir /tmp/test-project && cd /tmp/test-project | ||
| case "${{ matrix.project }}" in | ||
| cra) | ||
| bun create react-app@latest . --template typescript | ||
| bun install | ||
| ;; | ||
|
||
| vite) | ||
| bun create vite@5 . --template react-ts | ||
| bun install | ||
| ;; | ||
| esac | ||
| # 로컬 daleui 패키지 설치 | ||
| bun add "$GITHUB_WORKSPACE" | ||
| # ======================================== | ||
| # 실제로 daleui 써보는 smoke test 페이지 추가 | ||
| # ======================================== | ||
| - name: Add daleui smoke test | ||
| run: | | ||
| cd /tmp/test-project | ||
| mkdir -p src/smoke | ||
| cat > src/smoke/DaleTest.tsx << 'EOF' | ||
| import { Button } from 'daleui'; | ||
| export default function DaleTest() { | ||
| return ( | ||
| <div data-testid="daleui-smoke"> | ||
| <Button>daleui 성공적으로 로드됨!</Button> | ||
| </div> | ||
| ); | ||
| } | ||
| EOF | ||
| # ======================================== | ||
| # 최종 빌드 테스트 | ||
| # ======================================== | ||
| - name: Run production build | ||
| run: | | ||
| cd /tmp/test-project | ||
| bun run build | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@RiaOh 님, 우리 CRA 테스트는 그냥 하지 마시죠. CRA는 2022년 4월 이후로 업데이트가 전혀 없으며, React 공식 문서에서도 사라지면서 사실 상 폐기(deprecated) 수순을 밟고 있거든요. 워크플로우 로그를 보시면 high 단계 보안 취약점이 6개나 있는 걸 보면, 이 프로젝트 사실 상 제대로 유지보수가 되고 있다고 보기 어려울 것 같습니다. 2026년에는 React 생태계가 CRA에서 완전히 벗어나는 동참하는 차원에서 우리도 쓰지 말고, 사용자들도 쓰지 말라고 권장했으면 좋겠습니다.
CRA 제거하면 matrix 안 써도 되서 워크플로우도 간단해지고, 1분 내에 실행이 끝날 수 있을 것입니다. 워크플로우가 이제 PR이 병합될 때가 아니라 PR에 변경이 있을 때 마다 실행이 되기 때문에 빠른 피드백을 줄 수 있어서 개발자 경험에도 도움이 될 거에요.