Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [che-dev] Publish NPM package with tests

Radim thanks for bringing this up and sharing the tests as npm packages to avoid code duplication makes absolute sense. Other options would be to use npm git dependency (@benoitf did that for chectl a few weeks ago [1]) or a git submodules (automatically updated with dependabot). Anyway I like the npm package, it's the cleanest way to do it, but you still need to maintain the package.

[1] https://github.com/che-incubator/chectl/pull/115/files#diff-b9cfc7f2cdf78a7f4b91a753d10865a2

On Thu, Jun 20, 2019 at 7:28 AM Radim Hopp <rhopp@xxxxxxxxxx> wrote:
Thanks!
If my understanding is correct and the plan I scetched out in my previous email is ok with everybody, all what is required from you would be just adding secret NPM_AUTH_TOKEN to che-master-ci job (the secret is already present in release-all job). Everything else should be our responsibility in the code AFAIK. But yeah... Better check with Roman, if you have the possibility ;-)
Thanks!

On Wed, Jun 19, 2019 at 4:25 PM Vitalii Parfonov <vparfono@xxxxxxxxxx> wrote:
Hi, Radim
This is something new for me  me i will communicate with Roman about this Job. 
Will inform your soon

On Wed, Jun 19, 2019 at 10:00 AM Radim Hopp <rhopp@xxxxxxxxxx> wrote:
Hi Vitalii, Florent, Yevhen & all
I was looking at this a bit and I see we have already place to push our npm packages to. When I was looking at how packages get there, I see they get published by this job - and it's just packages from che-theia repo.
What we would like to do is to have the package from eclipse/che repo, e2e directory published there as well (ideally as part of nigtly builds & release builds). What's the easiest and best way to do this?
What I've thought of so far is something like this:

1) We will add `e2e` folder as mvn module - meaning we will have also pom.xml in the `e2e` folder, which will just do something like `npm build` on compile phase and `npm publish` on install phase. (Ugh... I don't like that already - mixing mvn & npm :-D). This way, the npm package should be built & published as part of each build.
2) Somebody with rights to edit jenkins jobs will add credentials for pushing to  eclipse-che space in npm registry  (`NPM_AUTH_TOKEN` from jenkins secrets store) to che nightly & release builds.

I'm aware the build part is a bit tricky, as it has to be done in docker container to ensure all dependencies are present (basically the same way dashboard is being built right now) and also there would have to be some logic to not push to npm registry, when credentials are not provided...

Does this plan sound ok? Who should we cooperate on editing the jenkins job config? Is it you, Vitalii?
Thanks
Radim



On Tue, Jun 18, 2019 at 3:22 PM Katerina Foniok <kkanova@xxxxxxxxxx> wrote:
Hi guys,

a Happy Path tests were written in typescript in Che [1].
In RH-Che we would like to reuse this code, so it would be cool to have these tests published as NPM package and simply add that as a dependency on RH-Che side. 
We wrote some workaround for that - we are downloading this e2e subdirectory from github and linking it as a local dependency. But its quite messy and having a published package would make whole process much easier. Even handling some versioning is not that easy as it should be having a tagged published package. 

So my question is - is there some process already set up for some other NPM package, which is published on release and nightly builds? Is there some NPM user/organisation created for this purpose so we can reuse it? 

Thank you very much for your responses and help!
Katka

_______________________________________________
che-dev mailing list
che-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://www.eclipse.org/mailman/listinfo/che-dev


--

VITALII PARFONOV

PRINCIPAL SOFTWARE ENGINEER, CHE PROJECT

Red Hat EMEA

Ukraine

M: VPARFONO@xxxxxxxxxx    

_______________________________________________
che-dev mailing list
che-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://www.eclipse.org/mailman/listinfo/che-dev

Back to the top