-
Notifications
You must be signed in to change notification settings - Fork 17
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
Jest Tests List View #10
Comments
I would like to show you the first jest tests (not very complex of course) for formulaShareAbout but my VSC say 'You don't have permissions to push to 'LawrenceLoz/FormulaShare-DX' on GitHub. Would you like to create a fork and push to it instead?' Are there some permissions missing for this repo? |
Sounds great, looking forwards to taking a look! And yes if you're able to create a fork and branch there that would be great and I can take a look. Are you happy for us to follow this workflow? https://gist.github.com/Chaser324/ce0505fbed06b947d962 Thanks |
I hope I've done it the right way. Take a look here: sfdcschwabe@c2b8caf |
This looks great, thanks for getting this together so quickly! I'm not an expert but I think the level you've done for this component is good given its simplicity. I don't think I'll have a chance to review in detail until early next week but I'll take a closer look then and try running myself and researching more into the best aspects to cover |
No worries. I'm glad to help and gathering experiences in collaboration on GitHub with you on this project. Then I will move on further with testing the other components in more depth. |
Thanks and no problem, great to see your work so far and don't worry about going too quick, I'll catch up soon! Thanks a lot again for your contributions, it's looking great |
Hey Christian, Just had a chance to get Jest set up, run your tests and take a look at your work in the branch so far. In general it looks great - fantastic to see this all in place. If anything I'd suggest slightly less thorough HTML testing would be enough to ensure high level checks are made on the page of the most important elements, but that we don't check everything to reduce effort for simpler components and retain flexibility for page structure changes without significant test rewrites. Hopefully this will help you have more time for the more complicated aspects of components with more Javascript as well. But think everything so far is great to keep, really happy this will be part of the project and big thanks again! Lawrence |
Hi Lawrence, for any kind of reason I am not able to @mention you directly on a commit in my branch. See: sfdcschwabe@25f28d0#commitcomment-44895302 |
Thanks I've just responded. Not sure what the issue is with @mentions - it might allow this now that I've commented in your repo |
FYI - Added new tests: sfdcschwabe@ee37322 I'm not finished yet with the component formulaShareRulesListView.js, but want to share the current outcomes. Remember: These are my very fest written jest tests. I hope there are things to optimize. But for now: This level of experience is all I can give. |
Thanks Christian. I've had a look through and from my perspective looks really good so far (jest is new to me too but trying to keep up and use this as a chance to learn good practices as well). I've added a comment around the report tests but I can't see any improvements around other aspects - general all seems in keeping with the examples I've seen in the lwc-recipes repo |
I can only mention you when you start commenting on a new commit after the first time. |
Under https://www.salesforcetroop.com/ are some nice contents (article, videos) about jest testing: |
Finally. The test coverage looks like the following: ----------------------------------------|---------|----------|---------|---------|-------------------------------------------------------------------------------
When we can clearify the following open questions regarding testing error handling and toast messages - we got it! :) |
Fantastic, this is looking really good! Hopefully the responses make sense and let me know if you want to check in on anything else |
I've just wrote a reminder to the open questions where I didn't find an answer. Looking forward: What could be the next issue or thing to work on? :) |
Given you've been looking at it quite a bit so far perhaps implementing a generic toast service and/or any alternative approach for presenting errors in a different way (happy for you to recommend and prototype an error panel approach if you think this gives a better look and feel) Alternatively working on a component to be added to a record page to show sharing would be very useful, although this would be a longer term task. Let me know if you want to go this route and I'll create an issue with some detail around what would be needed. You're honestly welcome to select whatever interests you the most though from things we've agreed would be beneficial, or if you'd like to propose something else that's fine too. It's your time so I think the most important thing is that it's something which you're enjoying working on or learning |
I would feel safest to first revise the ToastMessages and implement my suggestion. Then I'm curious about your feedback. About the other thing regarding the display of shares: What do you have in mind? You are welcome to create an issue for it. For me to introduce myself: Do you mean a display of shares like it already exists in Classic? |
All sounds good. In terms of the page component, I think this would be a little like the sharing button in classic (which is finally coming to Lightning soon! https://help.salesforce.com/articleView?id=release-notes.rn_forcecom_manual_sharing_lex.htm&language=en_us&r=https%3A%2F%2Fwww.google.com%2F&release=230&type=5), but this would provide additional information and functionality which is tailored to FormulaShare sharing. It would be good to have a link to view the rule responsible for the sharing and/or show some context from the rule against the share. There could also be an option to recalculate sharing for the record, and maybe some other things. I'll get some thoughts together and pull together in an issue over the next few days. |
To create Jest tests to cover functionality of the components on the FormulaShare Rules list page:
formulaShareRulesPage
formulaShareRulesListView
formulaShareScheduleJobDescription
formulaShareNoRulesIllustration
formulaShareAbout
The text was updated successfully, but these errors were encountered: