-
Notifications
You must be signed in to change notification settings - Fork 62
WIP : refactor jenkinsfile with new npm targets #2364
Conversation
abstract build steps from jenkins.
package.json
Outdated
"build-planner": "npm install && npm run build && npm pack dist/", | ||
"unit-test": "npm run test:unit", | ||
"setupFuncTestEnv": "/usr/bin/Xvfb :99 -screen 0 1440x900x24 &", | ||
"func-test": "npm run -s setupFuncTestEnv && cd runtime && export API_URL=https://api.prod-preview.openshift.io/api/ && export NODE_ENV=inmemory && npm install && ./tests/run_functional_tests.sh smokeTest" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do you want to export API_URL
and use inmemory
mode at the same time?
When we set NODE_ENV=inmemory
mode, planner uses the mock
services. It will ignore the API_URL
.
Also, run_functional_tests
script always sets NODE_ENV=inmemory
mode and then starts the planner. You could write this line as
npm run -s setupFuncTestEnv && cd runtime && npm install && ./tests/run_functional_tests.sh smokeTest
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jarifibrahim thanks! now, this is what exactly I am trying to find out.
I am just extracting contents from release.groovy to npm targets. It was mentioned here in https://github.com/fabric8-ui/fabric8-planner/blob/master/deploy/release.groovy#L20
can you please confirm we do not need it this way?
And I am trying your suggestion, let's see.
…e so no need to export that as well.
npm ERR! As of npm@5, the npm cache self-heals from corruption issues and data extracted from the cache is guaranteed to be valid. If you want to make sure everything is consistent, use 'npm cache verify' instead. npm ERR! npm ERR! If you're sure you want to delete the entire cache, rerun this command with --force.
sh 'npm install' | ||
sh 'npm run build' | ||
sh 'npm pack dist/' | ||
sh 'npm run build-planner' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You haven't changed anything but making it more opaque. I do NOT think this is good.
Nothing has changed, only the wording. What is the point? |
Thanks @joshuawilson for your concern but at this point, I am just trying to learn stuff. nothing else. |
"semantic-release": "semantic-release pre && gulp build && cp -r .git dist && npm publish dist/ && semantic-release post" | ||
"semantic-release": "semantic-release pre && gulp build && cp -r .git dist && npm publish dist/ && semantic-release post", | ||
"build-planner": "npm install && npm run build && npm pack dist/", | ||
"unit-test": "npm run test:unit" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is the difference between npm run test:unit
and npm run unit-test
?
They do the same thing but you move away from the standard format of listing the action first. What is the point?
@pranavgore09 fabric8/fabric8-ui:SNAPSHOT-PR-2364-18 is deployed and available for testing at https://fabric8-ui-fabric8-ui-pr-2364-fabric8-planner.badger.fabric8.io |
@pranavgore09 fabric8/fabric8-ui:SNAPSHOT-PR-2364-19 is deployed and available for testing at https://fabric8-ui-fabric8-ui-pr-2364-fabric8-planner.badger.fabric8.io |
Filed #2376 which should be a blocker to this PR. |
This PR is now obsolete as confirmed with @pranavgore09 over IM. |
just testing
ToDo
thinks
that it is using new planner or it isreally always
using new planner. Do this by following steps- make some breaking changes in planner (only integrated setup should fail)
- clean the cache before running
npm run build:prod
in fabric8-ui