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

(fix/reuse-fragments) New test case for issue with implementing not existing classes #438

Conversation

LiLatee
Copy link
Contributor

@LiLatee LiLatee commented Jan 8, 2024

@knaeckeKami as you wanted I added a new test case that doesn't work in my case.

I am not sure if it's done as you prefer and I was not able to test it using that repository, because as I saw it doesn't use local versions of packages and instead it uses versions from pub.dev and unfortunately I haven't found a quick way to overcome it 😅

@knaeckeKami
Copy link
Collaborator

knaeckeKami commented Jan 8, 2024

you can use

dart pub global activate multipack

multipack pubspec override to use the local packages (must be called from the root dir)

and then when you are done

multipack pubspec clean before committing

@LiLatee
Copy link
Contributor Author

LiLatee commented Jan 8, 2024

Oh, that's something new to me and It works. Thanks! ❤️ But I see that my case doesn't produce an error right now. So I have to dive into it again. I will let you know when it's ready.

@knaeckeKami
Copy link
Collaborator

knaeckeKami commented Jan 8, 2024

probably because end_to_end_test is not using reuse_fragments right now.

But that's fine, we can just use this query a test case for #417

@LiLatee
Copy link
Contributor Author

LiLatee commented Jan 8, 2024

But I see that my case doesn't produce an error right now

My mistake... I've created a branch using #417 instead of your https://github.com/gql-dart/gql/tree/repro_reuse_fragments

I can create a proper one tomorrow 😞

but it was also true :D

probably because end_to_end_test is not using reuse_fragments right now.

@LiLatee
Copy link
Contributor Author

LiLatee commented Jan 9, 2024

@knaeckeKami now it's fine. I mean now after enabling reuse_fragments connection.data.gql.dart will use not existing class.

@knaeckeKami
Copy link
Collaborator

Thanks! it will probably show that error on #417 though, which master does not have yet. but that will it make easier figure it out

@knaeckeKami
Copy link
Collaborator

pls run code generation so that the generated code is check into the end to end test

@LiLatee
Copy link
Contributor Author

LiLatee commented Jan 9, 2024

pls run code generation so that the generated code is check into the end to end test

Sure. @knaeckeKami Should I run it with reuse-fragments disabled? Or should I enable it manually for the time of generation inside data_builder.dart?

@knaeckeKami
Copy link
Collaborator

For now, it's sufficient to run it with reuse_fragments disabled.

When we officially ship this, we can think about proper test coverage of code gen with and without reuse_fragment

@LiLatee
Copy link
Contributor Author

LiLatee commented Jan 9, 2024

@knaeckeKami done 👌

@knaeckeKami knaeckeKami merged commit 76306e5 into gql-dart:repro_reuse_fragments Jan 13, 2024
17 of 20 checks passed
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