Vscode-icons: [Proposal] Move 'icons.json' to dist

Created on 4 Dec 2016  路  21Comments  路  Source: vscode-icons/vscode-icons

Obviously this is something trivial, but out of build process consistency, any file that is produced by the build script, SHOULD be placed in the dist folder.

As long as we reflect the move in the package.json file and the generated paths, I can't see any issues.

question / debate suggestion

All 21 comments

Agreed. @JimiC's #488 takes the lead.

EDIT: I referenced #408 but it was an error.

@robertohuertasm @jens1o One thing that is critical, if we move icons.json to dist, thus not include it in the repo anymore, is that we need to at least add some basic testing to the project. One example is to check if the supported extensions is backed by an associated icon file (happened to me on a PR and thankfully Jens noticed it).

So the question is, is there a preferred testing frameworks to use?
Personally, I'm familiar with:

I prefer mocha-chai but can consider jasmine and ava as an option too.
Your thoughts?

That's right @JimiC, but I'm unfamiliar with any of theses testing frameworks. At the first look, I prefer jasmine over Mocha. But in general, they work the same way, don't they?

@jens1o They are practically the same but mocha-chai utilizes Promises via chai which makes the async chaining easier.

Further more look at the trends.

Here is an example of how mocha-chai looks like vs to how mocha looks like vs how ava looks like.

Hi guys, I'm personally a big fan of jest but if I had to choose between all you mentioned I would choose Mocha & Chai.

Looking at jest it looks like an extend of jasmine and mostly shines when used with React. I think it's overkill to use jest for now. Same reason I didn't proposed karma (with is used by Angular).

I too think we should go with mocha-chai for now.

If we all agree, I'll start writing some basic tests.

I don't think Jest is overkilling. In fact it reduces the noise of using several testing libraries, it makes working with promises easier (as Mocha-Chai does), it can load tests in a parallel way speeding up the testing process and you've got Istanbul for free included. Karma is a test runner not a test library so I don't see how it would fit in a comparison here but anyway, being that you all prefer Mocha-Chai I don't have any objection to that 馃槈

Well I read that jest is mocking the entire node_modules and if you don't want that you need so tell it about it. Currently I don't think we need mocking abilities. It also needs a special reference in the project.json to point the test environment to node so it doesn't include window (we don't need that right?).

The overkill refers to perf impact mostly.

Where have you read that it mocks the entire node_modules? Just out of curiosity. As far as I know automock is disabled by default, I don't know if you're referring to that. 馃槈

Anyway, let's go with Mocha-Chai and let's get rid of bizantine discussions 馃槣

http://instea.sk/2016/08/testing-react-applications-with-karma-jest-or-mocha/
I like bizantine discussions, it's in my inheritance (if you know what I mean). 馃槤

Here's what I'll do. I'll do both and see.

@JimiC I'm well aware of your inheritance and you do justice to it :stuck_out_tongue_winking_eye:

Don't bother to do both implementations. I'm really ok with Mocha-Chai. I happens that I sometimes also like bizantine discussions. Just as a side comment, the article is assuming that automock is true, which indeed was true prior to Jest v.15

I've personally used Jasmine, Mocha-Chai-Sinon and Jest as test suites in the several projects I`ve been working in (in that specific order) and had a crush with Jest's simplicity. But I know this is really a very opinionated subject and there are no right or wrong answers. I would suggest you to try it in some of your projects and give it a try, even if you're not using React.

Let's go with Mocha-Chai :grin:

No, no, it's fine. I can try jest. I'm open in trying new things.

Guys. Don't fight. 馃槅

@robertohuertasm Is it OK if I use an external file to configure jest, something like jest.config.json?
I know it can be set inside package.json, but in my opinion it shouldn't be there.

@JimiC it's ok. No issues with that. But if you see it's going to be a pain let's move to Mocha-Chai or even ava, I've never tried it and for what I see it seems pretty interesting. 馃槈

@robertohuertasm I have already started with jest. It kinda feels like MSTest.

馃槅 and why is so? What triggered that connection?

The simplicity?

Something that feels missing in jest though is the Setup and TearDown.

Damn! Looking at the API Reference it's Jasmine all over again. 馃槅

So the main reason why I went with Jest after all is the fact that this project isn't mine and @robertohuertasm must be comfortable with everything and anything that we add to this project.

This also includes any decision to transpose the project to Typescript. But this is another topic.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

RomainLanz picture RomainLanz  路  3Comments

robertohuertasm picture robertohuertasm  路  4Comments

Alex-Sokolov picture Alex-Sokolov  路  3Comments

FDMatthias picture FDMatthias  路  4Comments

cgatian picture cgatian  路  3Comments