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

Dude! Where are the tests? #3

Open
yan-foto opened this issue Aug 14, 2015 · 7 comments
Open

Dude! Where are the tests? #3

yan-foto opened this issue Aug 14, 2015 · 7 comments

Comments

@yan-foto
Copy link
Owner

No description provided.

@yan-foto
Copy link
Owner Author

  • tests with jest/mocha
  • lint with jslint/eslint

@mackignacio
Copy link

Can I do this test? I can do Jest unit testing.

@yan-foto
Copy link
Owner Author

yan-foto commented Jun 1, 2019

Hey @mackignacio ! Thanks for the help, I really appreciate it. Please feel free to write some tests. The reason that I didn't write any test is not knowing the best approach to write integration tests for electron. Starting with unit tests, nonetheless, would be a good start!

@mackignacio
Copy link

@yan-foto Thanks!!!

@mackignacio
Copy link

@yan-foto I noticed that there are two functions to be tested and both of them are not testable. createHardresetHandler() only returns a function and the returned function return a void. Then the default exported function also returns a void. Can we make the function at least return something so we can make it testable.

@yan-foto
Copy link
Owner Author

yan-foto commented Aug 5, 2019

Not so fast 😄 !

Maybe the structure is not suitable for unit tests, but it sure is for integration tests. We should mock electron interfaces and see if electron-reload responses correctly to file changes.

Does that make sense?

@mackignacio
Copy link

Yeah that's also what I wanted to do.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants