application-passwords icon indicating copy to clipboard operation
application-passwords copied to clipboard

Unit Tests: Should we create them?

Open kjbenk opened this issue 10 years ago • 3 comments

I was reviewing this plugin last night and I realized that there were no unit tests within this plugin. I think we should create a couple of them to at least show these use cases.

  • [ ] Ping a public REST API endpoint - PASS
  • [ ] Ping a private REST API endpoint - FAIL
  • [ ] List passwords - PASS
  • [ ] Revoke passwords - PASS
  • [ ] Create passwords with a password - FAIL

Let me know if you have anymore. I am going to start creating these and send you a PR soon.

kjbenk avatar Feb 04 '16 12:02 kjbenk

@kasparsd it looks like you've added tests recently. Are there any others that you feel could/should be added or can we close out this issue?

jeffpaul avatar Sep 18 '20 15:09 jeffpaul

Yeah, unfortunately is just one set of tests for the HTTP login part of the codebase. Would be nice to add some coverage for the areas that @kjbenk mentioned. @jeffpaul Would you suggest opening a new issue for that and defining the critical areas to be tested or repurpose this issue?

kasparsd avatar Sep 18 '20 15:09 kasparsd

@kasparsd might as well repurpose this issue and update the checklist in the original description or note what the current checklist items to resolve are in a subsequent comment so we can work towards adding those tests and getting this work closed out.

jeffpaul avatar Sep 18 '20 15:09 jeffpaul