hexo icon indicating copy to clipboard operation
hexo copied to clipboard

Introducing test utils

Open ertrzyiks opened this issue 6 years ago • 1 comments

Not a problem this time, but I would like to share an idea. It's something I was working on during last weeks.

I've seen and use a lot of nice plugins to Hexo, but only few are automatically tested. With Hexo is very easy to write test for plugin, but the boilerplate code needed for it may discourage to try.

To improve the situation and ease adding specs for plugins I came up with hexo-test-utils. It's a Sandbox and set of utilities. Currently, it has only those I needed for https://github.com/hexojs/hexo-filter-responsive-images . It could and should have way more.

The documenation for the current API is here

@NoahDragon if you like the idea, I will move the repo to the organization

ertrzyiks avatar Apr 15 '18 18:04 ertrzyiks

@hexojs/core any thoughts on that?

I'm still actively developing those utils, plan to add more documentation which would be also a nice introduction to Hexo internals I think. Would you and your plugins/themes benefit from such a library?

ertrzyiks avatar May 16 '18 10:05 ertrzyiks