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(angular-table): add test case #5568

Merged
merged 16 commits into from
May 23, 2024

Conversation

riccardoperra
Copy link
Contributor

@riccardoperra riccardoperra commented May 19, 2024

I'm introducing some test cases to check the FlexRenderDirective and createAngularTable behaviors.

The setup is the same of @tanstack/angular-query, so we are currently using vitest and @analogjs plugin. We can may add in the future some test with angular-testing-library to do some rendering testing like the react package

I have found somes issues to the proxy implementation:

  • we were transforming to computed signals also functions like getCoreRowModel
  • Object.keys(table) and key in table were throwing an error due to the function prototype, so I've updated the proxy target to an arrow function

In a previous commit we also removed the Signal signature to the createAngularTable return type. I've reintroduced it since our table object is both signal and proxy

Copy link

nx-cloud bot commented May 19, 2024

☁️ Nx Cloud Report

CI is running/has finished running commands for commit bd70b62. As they complete they will appear below. Click to see the status, the terminal output, and the build insights.

📂 See all runs for this CI Pipeline Execution


✅ Successfully ran 1 target

Sent with 💌 from NxCloud.

@riccardoperra riccardoperra marked this pull request as ready for review May 20, 2024 08:14
@KevinVandy
Copy link
Member

I can't figure out why I'm getting this error when running the project locally now

image

@riccardoperra
Copy link
Contributor Author

I'll try to look into it this evening. I did a fast check and had the same error :/

In my previous experiences I had a similiar issue when node_modules was not clean, for example when multiple angular version were installed. Could this be related to the pnpm v9 and nx update? 🤔

@riccardoperra
Copy link
Contributor Author

Fyi this seems a similar issue
angular/angular#55709

@riccardoperra
Copy link
Contributor Author

riccardoperra commented May 22, 2024

@KevinVandy I don't know what happened, but I can confirm to you this is an issue related to some installed deps issue

After doing the below steps in order, I'm now able again to run the examples without any issues :/

  1. remove all node_modules and build folder
find . -path '*/node_modules/*' -delete
find . -path '*/build/*' -delete
  1. remove pnpm-lock.yaml

  2. remove .nx folder

  3. run pnpm store prune --force

  4. run pnpm install

  5. run pnpm build

I updated all package.json in order to have the same installed angular version (17.3.9)


IMPORTANT

This thing make me crazy 😄 Updating angular with the same version is not enough. I have to remove also pnpm-lock.yaml and recreate everything from scratch. Unfortunately this cause some issues while building the qwik demos which break the CI (look to the previous run error https://github.com/TanStack/table/actions/runs/9197713380)

EDIT 2

Everything seems working in my machine and in the CI after pnpm dedupe, but I don't know if this is ok for you.
https://pnpm.io/cli/dedupe

@KevinVandy KevinVandy merged commit 11a5b4d into TanStack:main May 23, 2024
2 checks passed
@riccardoperra riccardoperra deleted the test/flex-render-test branch May 23, 2024 04:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants