Skip to content

Commit

Permalink
Release 12.1.0
Browse files Browse the repository at this point in the history
  • Loading branch information
benm071 committed Apr 14, 2022
1 parent b04eb15 commit 55c6fa5
Show file tree
Hide file tree
Showing 18 changed files with 78 additions and 42 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# @oracle/ojet-cli 12.0.0
# @oracle/ojet-cli 12.1.0

## About the module
This module contains a command line interface for Oracle JET web and hybrid mobile application development.
Expand Down Expand Up @@ -64,7 +64,7 @@ Or view help on adding a plugin:
ojet help add plugin
```

For more information on the Oracle JET CLI, refer to the [Oracle JET Developers Guide](http://www.oracle.com/pls/topic/lookup?ctx=jet1200&id=homepage).
For more information on the Oracle JET CLI, refer to the [Oracle JET Developers Guide](http://www.oracle.com/pls/topic/lookup?ctx=jet1210&id=homepage).

## [Contributing](https://github.com/oracle/ojet-cli/blob/master/CONTRIBUTING.md)
Oracle JET is an open source project. Pull Requests are currently not being accepted. See [CONTRIBUTING](https://github.com/oracle/ojet-cli/blob/master/CONTRIBUTING.md) for details.
Expand Down
4 changes: 4 additions & 0 deletions RELEASENOTES.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
## Release Notes for ojet-cli ##

### 12.1.0

* Bug fixes

### 12.0.0

* Add optional 'stripList' property to oraclejetconfig.json to allow providing the list of files/directories to delete instead of using .gitignore
Expand Down
2 changes: 1 addition & 1 deletion common/template/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ const constants = require('../../lib/util/constants');
const _HYBRID = 'hybrid';
const _WEB = 'web';

const _TEMPLATES_NPM_URL = '@oracle/oraclejet-templates@~12.0.0';
const _TEMPLATES_NPM_URL = '@oracle/oraclejet-templates@~12.1.0';

module.exports =
{
Expand Down
4 changes: 2 additions & 2 deletions generators/app/templates/common/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@
"version": "1.0.0",
"description": "An Oracle JavaScript Extension Toolkit(JET) web app",
"dependencies": {
"@oracle/oraclejet": "~12.0.0"
"@oracle/oraclejet": "~12.1.0"
},
"devDependencies": {
"fs-extra": "^8.1.0",
"glob": "^7.1.1",
"underscore": "^1.10.2",
"@oracle/oraclejet-tooling": "~12.0.0"
"@oracle/oraclejet-tooling": "~12.1.0"
},
"engines": {
"node": ">=12.21.0"
Expand Down
4 changes: 2 additions & 2 deletions generators/hybrid/templates/common/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@
"version": "1.0.0",
"description": "An Oracle JavaScript Extension Toolkit (JET) mobile app",
"dependencies": {
"@oracle/oraclejet": "~12.0.0"
"@oracle/oraclejet": "~12.1.0"
},
"devDependencies": {
"fs-extra": "^8.1.0",
"glob": "^7.1.1",
"underscore": "^1.10.2",
"@oracle/oraclejet-tooling": "~12.0.0"
"@oracle/oraclejet-tooling": "~12.1.0"
},
"engines": {
"node": ">=12.21.0"
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@oracle/ojet-cli",
"version": "12.0.0",
"version": "12.1.0",
"description": "Oracle JET Command Line Interface",
"license": "UPL-1.0",
"homepage": "http://www.oracle.com/jet",
Expand All @@ -14,7 +14,7 @@
"inquirer": "~6.2.2",
"minimist": "~1.2.0",
"xmldom": "0.5.0",
"@oracle/oraclejet-tooling": "~12.0.0"
"@oracle/oraclejet-tooling": "~12.1.0"
},
"engines": {
"node": ">=12.21.0"
Expand Down
2 changes: 1 addition & 1 deletion template/component/js/component.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@component-name@",
"version": "1.0.0",
"jetVersion": "^12.0.0",
"jetVersion": "^12.1.0",
"displayName": "A user friendly, translatable name of the component.",
"description": "A translatable high-level description for the component.",
"properties": {
Expand Down
2 changes: 1 addition & 1 deletion template/component/ts/component.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@component-name@",
"version": "1.0.0",
"jetVersion": "^12.0.0",
"jetVersion": "^12.1.0",
"displayName": "A user friendly, translatable name of the component.",
"description": "A translatable high-level description for the component.",
"properties": {
Expand Down
2 changes: 1 addition & 1 deletion template/resource-component/component.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "@component-name@",
"type": "resource",
"version": "1.0.0",
"jetVersion": "^12.0.0",
"jetVersion": "^12.1.0",
"displayName": "A user friendly, translatable name of the component.",
"description": "A translatable high-level description for the component.",
"publicModules": [
Expand Down
15 changes: 15 additions & 0 deletions test/componentTest.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ const VCOMPONENT_NAME = 'vcomp-1';
const DEFAULT_COMPONENT_VERSION = '1.0.0';
const EXCHANGE_COMPONENT_PACK = 'oj-dynamic';
const EXCHANGE_COMPONENT_PACK_MEMBER = 'form';
const BUNDLE_TEST_EXCHANGE_COMPONENT = 'oj-sample-metric';
const EXCHANGE_COMPONENT_NAME = `${EXCHANGE_COMPONENT_PACK}-${EXCHANGE_COMPONENT_PACK_MEMBER}`;

const PACK_NAME = 'pack-1';
Expand Down Expand Up @@ -378,6 +379,17 @@ describe('Component & Jet Pack Tests', () => {
});
}

function buildReleaseExchangeComponentTest({ appName, pack }) {
describe('check that build release command on exchange components with bundle definitions runs successfully', () => {
it('should successfully build and release an app using exchange component with bundle definitions', async () => {
const appDir = util.getAppDir(appName);
await util.execCmd(`${util.OJET_APP_COMMAND} add component ${pack}`, { cwd: appDir }, true, true);
const result = await util.execCmd(`${util.OJET_APP_COMMAND} build --release`, { cwd: appDir }, true, true);
assert.equal(util.buildSuccess(result.stdout), true, result.error);
});
});
}

function packageComponentTest({ appName, component }) {
if (!util.noScaffold()) {
beforeComponentTest({ task: 'package', app: appName, component });
Expand Down Expand Up @@ -761,6 +773,9 @@ describe('Component & Jet Pack Tests', () => {
describe('ojet build --release', () => {
util.runComponentTestInAllTestApps({ test: buildComponentAppTest, component: [COMPONENT_NAME, COMPONENT_NAME_COMPOSITE, VCOMPONENT_NAME], release: true });
});
describe('ojet build --release (bundle)', () => {
util.runComponentTestInAllTestApps({ test: buildReleaseExchangeComponentTest, pack: BUNDLE_TEST_EXCHANGE_COMPONENT});
});
describe(`ojet build --${util.OMIT_COMPONENT_VERSION_FLAG}`, () => {
util.runComponentTestInAllTestApps({ test: omitComponentVerstionTest });
});
Expand Down
2 changes: 1 addition & 1 deletion test/templates/webTsApiTest/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"version": "1.0.0",
"description": "An Oracle JavaScript Extension Toolkit(JET) web app",
"dependencies": {
"@oracle/oraclejet": "https://artifacthub-phx.oci.oraclecorp.com/ojet-dev-local/oracle-oraclejet-12.0.0.tgz"
"@oracle/oraclejet": "https://artifacthub-phx.oci.oraclecorp.com/ojet-dev-local/oracle-oraclejet-12.1.0.tgz"
},
"devDependencies": {
"@oracle/oraclejet-tooling":"file:../../ojet-cli/node_modules/@oracle/oraclejet-tooling",
Expand Down
2 changes: 1 addition & 1 deletion test/templates/webTsApiTest/src/js/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
{
'knockout': 'libs/knockout/knockout-3.5.1.debug',
'jquery': 'libs/jquery/jquery-3.5.1',
'jqueryui-amd': 'libs/jquery/jqueryui-amd-1.12.1',
'jqueryui-amd': 'libs/jquery/jqueryui-amd-1.13.0',
'hammerjs': 'libs/hammer/hammer-2.0.8',
'ojdnd': 'libs/dnd-polyfill/dnd-polyfill-1.0.2',
'ojs': 'libs/oj/v10.0.0/debug',
Expand Down
16 changes: 9 additions & 7 deletions test/templates/webTsApiTest/src/js/path_mapping.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
"use": "local",
"cdns": {
"jet": {
"prefix": "https://ci-cloud.us.oracle.com/jenkins/uitech/job/CDN_12.0.0/lastSuccessfulBuild/artifact/cdn/v12.0.0/default/js",
"css": "https://ci-cloud.us.oracle.com/jenkins/uitech/job/CDN_12.0.0/lastSuccessfulBuild/artifact/cdn/v12.0.0/default/css",
"prefix": "https://ci-cloud.us.oracle.com/jenkins/uitech/job/CDN_12.1.0/lastSuccessfulBuild/artifact/cdn/v12.1.0/default/js",
"css": "https://ci-cloud.us.oracle.com/jenkins/uitech/job/CDN_12.1.0/lastSuccessfulBuild/artifact/cdn/v12.1.0/default/css",
"config": "bundles-config.js"
},
"3rdparty": "https://ci-cloud.us.oracle.com/jenkins/uitech/job/CDN_12.0.0/lastSuccessfulBuild/artifact/cdn/v12.0.0/3rdparty"
"3rdparty": "https://ci-cloud.us.oracle.com/jenkins/uitech/job/CDN_12.1.0/lastSuccessfulBuild/artifact/cdn/v12.1.0/3rdparty"
},
"libs": {
"knockout": {
Expand Down Expand Up @@ -45,20 +45,22 @@
"*.js",
"widgets/draggable.js",
"widgets/mouse.js",
"widgets/sortable.js"
"widgets/sortable.js",
"vendor/jquery-color/jquery.color.js"
],
"path": "libs/jquery/jqueryui-amd-#{version}",
"cdnPath": "jquery/jqueryui-amd-1.12.1"
"cdnPath": "jquery/jqueryui-amd-1.13.0"
},
"release": {
"src": [
"*.js",
"widgets/draggable.js",
"widgets/mouse.js",
"widgets/sortable.js"
"widgets/sortable.js",
"vendor/jquery-color/jquery.color.js"
],
"path": "libs/jquery/jqueryui-amd-#{version}.min",
"cdnPath": "jquery/jqueryui-amd-1.12.1.min"
"cdnPath": "jquery/jqueryui-amd-1.13.0.min"
}
},
"hammerjs": {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "resources",
"version": "1.0.0",
"jetVersion": "^12.0.0",
"jetVersion": "^12.1.0",
"type": "resource",
"pack": "my-pack"
}
4 changes: 2 additions & 2 deletions test/templates/webpackLegacyTest/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
"version": "1.0.0",
"description": "An Oracle JavaScript Extension Toolkit(JET) web app",
"dependencies": {
"@oracle/oraclejet": "https://artifacthub-phx.oci.oraclecorp.com/ojet-dev-local/oracle-oraclejet-12.0.0.tgz"
"@oracle/oraclejet": "https://artifacthub-phx.oci.oraclecorp.com/ojet-dev-local/oracle-oraclejet-12.1.0.tgz"
},
"devDependencies": {
"@oracle/oraclejet-tooling": "https://artifacthub-phx.oci.oraclecorp.com/ojet-dev-local/oracle-oraclejet-tooling-12.0.0.tgz",
"@oracle/oraclejet-tooling": "https://artifacthub-phx.oci.oraclecorp.com/ojet-dev-local/oracle-oraclejet-tooling-12.1.0.tgz",
"fs-extra": "^8.1.0",
"glob": "^7.1.1",
"typescript": "4.5.4",
Expand Down
16 changes: 9 additions & 7 deletions test/templates/webpackLegacyTest/path_mapping.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
"use": "local",
"cdns": {
"jet": {
"prefix": "https://ci-cloud.us.oracle.com/jenkins/uitech/job/CDN_12.0.0/lastSuccessfulBuild/artifact/cdn/v12.0.0/default/js",
"css": "https://ci-cloud.us.oracle.com/jenkins/uitech/job/CDN_12.0.0/lastSuccessfulBuild/artifact/cdn/v12.0.0/default/css",
"prefix": "https://ci-cloud.us.oracle.com/jenkins/uitech/job/CDN_12.1.0/lastSuccessfulBuild/artifact/cdn/v12.1.0/default/js",
"css": "https://ci-cloud.us.oracle.com/jenkins/uitech/job/CDN_12.1.0/lastSuccessfulBuild/artifact/cdn/v12.1.0/default/css",
"config": "bundles-config.js"
},
"3rdparty": "https://ci-cloud.us.oracle.com/jenkins/uitech/job/CDN_12.0.0/lastSuccessfulBuild/artifact/cdn/v12.0.0/3rdparty"
"3rdparty": "https://ci-cloud.us.oracle.com/jenkins/uitech/job/CDN_12.1.0/lastSuccessfulBuild/artifact/cdn/v12.1.0/3rdparty"
},
"libs": {
"knockout": {
Expand Down Expand Up @@ -45,20 +45,22 @@
"*.js",
"widgets/draggable.js",
"widgets/mouse.js",
"widgets/sortable.js"
"widgets/sortable.js",
"vendor/jquery-color/jquery.color.js"
],
"path": "libs/jquery/jqueryui-amd-#{version}",
"cdnPath": "jquery/jqueryui-amd-1.12.1"
"cdnPath": "jquery/jqueryui-amd-1.13.0"
},
"release": {
"src": [
"*.js",
"widgets/draggable.js",
"widgets/mouse.js",
"widgets/sortable.js"
"widgets/sortable.js",
"vendor/jquery-color/jquery.color.js"
],
"path": "libs/jquery/jqueryui-amd-#{version}.min",
"cdnPath": "jquery/jqueryui-amd-1.12.1.min"
"cdnPath": "jquery/jqueryui-amd-1.13.0.min"
}
},
"hammerjs": {
Expand Down
22 changes: 11 additions & 11 deletions test/templates/webpackLegacyTest/src/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
as shown at https://oss.oracle.com/licenses/upl/
*/
/**
* @license
* Copyright (c) 2014, 2021, Oracle and/or its affiliates.
* Licensed under The Universal Permissive License (UPL), Version 1.0
* as shown at https://oss.oracle.com/licenses/upl/
* @ignore
*/
/**
* @license
* Copyright (c) 2014, 2021, Oracle and/or its affiliates.
* Licensed under The Universal Permissive License (UPL), Version 1.0
* as shown at https://oss.oracle.com/licenses/upl/
* @ignore
*/
'use strict';

/**
Expand All @@ -31,12 +31,12 @@
*/
// injector:mainReleasePaths
{
'ojs': 'libs/oj/v12.0.0/debug',
'ojL10n': 'libs/oj/v12.0.0/ojL10n',
'ojtranslations': 'libs/oj/v12.0.0/resources',
'ojs': 'libs/oj/v12.1.0/debug',
'ojL10n': 'libs/oj/v12.1.0/ojL10n',
'ojtranslations': 'libs/oj/v12.1.0/resources',
'knockout': 'libs/knockout/knockout-3.5.1.debug',
'jquery': 'libs/jquery/jquery-3.6.0',
'jqueryui-amd': 'libs/jquery/jqueryui-amd-1.12.1',
'jqueryui-amd': 'libs/jquery/jqueryui-amd-1.13.0',
'text': 'libs/require/text',
'hammerjs': 'libs/hammer/hammer-2.0.8',
'signals': 'libs/js-signals/signals',
Expand Down
13 changes: 13 additions & 0 deletions test/webpackTest.js
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,19 @@ describe('Webpack Test', () => {
assert.ok(false);
}
});
it('should have oj-redwood-min.css link in index.html file in staging', () => {
const { pathToIndexHtml } = util.getAppPathData(util.WEBPACK_APP_NAME);
const indexHtmlContent = fs.readFileSync(pathToIndexHtml, { encoding: 'utf-8' });
const hasRedwoodTheme = /<link\s.*redwood-min.css">/.test(indexHtmlContent);
assert.ok(hasRedwoodTheme, `${pathToIndexHtml} does not have link to Redwood theme`);
});
it('should have <!-- css : redwood --> tag in index.html in src folder', () => {
const appDir = util.getAppDir(util.WEBPACK_APP_NAME);
const pathToSrcIndexHTML = path.join(appDir, 'src', 'index.html');
const indexHtmlContent = fs.readFileSync(pathToSrcIndexHTML, { encoding: 'utf-8' });
const hasRedwoodThemeTag = /(<!--\s*|@@)(css|js|img):([\w\/]+)(\s*-->)?/.test(indexHtmlContent);
assert.ok(hasRedwoodThemeTag, `${pathToSrcIndexHTML} does not have Redwood theme tag in src/index.html`);
});
});
});
describe('Webpack (Legacy)', () => {
Expand Down

0 comments on commit 55c6fa5

Please sign in to comment.