-
-
Notifications
You must be signed in to change notification settings - Fork 60
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
The state is not testable #204
Comments
Hi, Sorry for the late reply. Thanks for your feedback. I will work on providing those missing APIs. |
Thank you. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hey! Thanks for the great library.
I have encountered some difficulties in unit tests.
I want to place the textState in a viewModel/stateHolder or whatever it's called and be able to test it.
The first problem is that the RichTextState is not immutable as mentioned in below issue:
So, I cannot enforce the users of my state holder to change the textState only through the methods of my state holder.
The next problem is that I have the following code which is working as intended in the app but my test gives false positive (the
textState.textAlign
in test isLeft
):Next, being notified/reacting to textState changes is not easy which makes tests need the workaround mentioned in below issues:
Side problem:
Can you please provide a way to add link to the current selection (like how bold and italic work)?
The text was updated successfully, but these errors were encountered: