Skip to content

Commit

Permalink
Merge branch 'develop' into FORMS-9688_checkbox_proxy_component
Browse files Browse the repository at this point in the history
  • Loading branch information
barshatr committed Sep 5, 2023
2 parents 704bf3f + 08aff11 commit a3ee19f
Show file tree
Hide file tree
Showing 14 changed files with 1,702 additions and 446 deletions.
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ To generate a project, adjust the following command line to your needs:
mvn -B org.apache.maven.plugins:maven-archetype-plugin:3.2.1:generate \
-D archetypeGroupId=com.adobe.aem \
-D archetypeArtifactId=aem-project-archetype \
-D archetypeVersion=43\
-D archetypeVersion=44\
-D appTitle="My Site" \
-D appId="mysite" \
-D groupId="com.mysite"
Expand Down Expand Up @@ -91,15 +91,15 @@ Name | Default | Description
`datalayer` | `y` | Activate integration with [Adobe Client Data Layer](https://docs.adobe.com/content/help/en/experience-manager-core-components/using/developing/data-layer/overview.html).
`amp` | `n` | Enable [AMP](https://docs.adobe.com/content/help/en/experience-manager-core-components/using/developing/amp.html) support for genenerated project templates.
`enableDynamicMedia` | `n` | Enabled foundation DynamicMedia components in project policy settings and activates Dynamic Media features in Core Image component's policy.
`enableSSR` | `n` | Option to enable SSR for the front-end project
`precompiledScripts` | `n` | Option to [precompile](https://experienceleague.adobe.com/docs/experience-manager-core-components/using/developing/archetype/precompiled-bundled-scripts.html) the server-side scripts from `ui.apps` and attach them to the build as a secondary bundle artifact in the `ui.apps` project. `aemVersion` should be set to `cloud`.
`includeFormsheadless` | `n` | Includes [Forms Core Components](https://github.com/adobe/aem-core-forms-components) dependencies, ui.frontend.react.forms.af and headless artifacts.
`enableSSR` | `n` | Option to enable SSR for the front-end project
`precompiledScripts` | `n` | Option to [precompile](https://experienceleague.adobe.com/docs/experience-manager-core-components/using/developing/archetype/precompiled-bundled-scripts.html) the server-side scripts from `ui.apps` and attach them to the build as a secondary bundle artifact in the `ui.apps` project. `aemVersion` should be set to `cloud`.
`includeFormsheadless` | `n` | Includes [Forms Core Components](https://github.com/adobe/aem-core-forms-components) dependencies, ui.frontend.react.forms.af and headless artifacts.
`uiTestingFramework` | `cypress` | Testing framework used for generating UI tests (can be `cypress` or `wdio`).
## System Requirements

Archetype | AEM as a Cloud Service | AEM 6.5 | Java SE | Maven
---------|---------|---------|---------|---------
[43](https://github.com/adobe/aem-project-archetype/releases/tag/aem-project-archetype-43) | Continual | 6.5.7.0+ | 8, 11 | 3.3.9+
[44](https://github.com/adobe/aem-project-archetype/releases/tag/aem-project-archetype-44) | Continual | 6.5.7.0+ | 8, 11 | 3.3.9+

Setup your local development environment for [AEM as a Cloud Service SDK](https://docs.adobe.com/content/help/en/experience-manager-learn/cloud-service/local-development-environment-set-up/overview.html) or for [older versions of AEM](https://docs.adobe.com/content/help/en/experience-manager-learn/foundation/development/set-up-a-local-aem-development-environment.html).

Expand Down
3 changes: 2 additions & 1 deletion VERSIONS.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,5 @@ Archetype Version | AEM Version
20, 21, 22 | 6.5, 6.4, 6.3 + SP3
23 | 6.5, 6.4, 6.3 + SP3, AEM as a Cloud Service
24, 25, 26, 27 | 6.5.5, 6.4.8.1, AEM as a Cloud Service
28, 30, 31, 32, 33, 34, 35, 36, 37, 39, 40, 41, 42, 43 | 6.5.7, AEM as a Cloud Service
28, 30, 31, 32, 33, 34, 35, 36, 37, 39, 40, 41, 42, 43, 44 | 6.5.7, AEM as a Cloud Service
46 | 6.5.17, AEM as a Cloud Service
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@

<groupId>com.adobe.aem</groupId>
<artifactId>aem-project-archetype</artifactId>
<version>44-SNAPSHOT</version>
<version>45-SNAPSHOT</version>
<packaging>maven-archetype</packaging>

<name>AEM Multi-Module Archetype</name>
Expand Down
2 changes: 1 addition & 1 deletion src/main/archetype/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@
<aio.runtime.namespace>${env.AIO_RUNTIME_NAMESPACE}</aio.runtime.namespace>
<aio.runtime.auth>${env.AIO_RUNTIME_AUTH}</aio.runtime.auth>
#end
<core.wcm.components.version>2.23.0</core.wcm.components.version>
<core.wcm.components.version>2.23.2</core.wcm.components.version>
#if ( $includeCommerce == "y" )
<core.cif.components.version>2.12.0</core.cif.components.version>
<magento.graphql.version>9.1.0-magento242ee</magento.graphql.version>
Expand Down
3 changes: 1 addition & 2 deletions src/main/archetype/ui.tests.cypress/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,9 @@
# See the License for the specific language governing permissions and
# limitations under the License.

FROM cypress/included:12.12.0
FROM cypress/included:12.17.0

ENV APP_PATH /usr/src/app
## Install dependencies
RUN apt -qqy update \
# Generic dependencies
&& apt -qqy --no-install-recommends install \
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
*/

const { defineConfig } = require("cypress");

const reportsPath = process.env.REPORTS_PATH || 'cypress/results'
const authorURL = process.env.AEM_AUTHOR_URL || 'http://localhost:4502'
const authorName = process.env.AEM_AUTHOR_USERNAME || 'admin'
Expand All @@ -36,7 +35,9 @@ let config = {
},
e2e: {
setupNodeEvents(on, config) {
// implement node event listeners here
require('cypress-terminal-report/src/installLogsPrinter')(on, {
printLogsToConsole: "always",
});
},
baseUrl: authorURL,
reporter: 'cypress-multi-reporters',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,31 +24,55 @@ describe('AEM Assets', () => {
cy.AEMLogin(Cypress.env('AEM_AUTHOR_USERNAME'), Cypress.env('AEM_AUTHOR_PASSWORD'))
})

it('should be possible to upload an asset', () => {
// skip by default if the CDN is not accessible. Remove the .skip to run the test
it.skip('should be possible to upload an asset', () => {
const assetsPath = '/content/dam';
const imageName = 'image.png';
const imagePath = `${assetsPath}/${imageName}`;
const localImageName = 'image.png';
const localPath = `assets/${localImageName}`;
const uuid = () => Cypress._.random(0, 1e6)
const id = uuid()
const remoteImageName = `image-${id}.png`;
const imagePath = `${assetsPath}/${remoteImageName}`;

// Go to the Assets page.
cy.visit(`${Cypress.env('AEM_AUTHOR_URL')}/assets.html${assetsPath}`);

// Wait for any lazy loaded dialogs to appear
cy.wait(3000)


cy.intercept({url: '/content/dam.completeUpload.json', method: 'POST'}).as('completeupload')

// Add the file handle to the upload form
const localPath = `assets/${imageName}`;
cy.get('dam-chunkfileupload.dam-ChunkFileUpload > input').first().selectFile(localPath, {force: true})

// rename image
cy.get('input#dam-asset-upload-rename-input').clear().type(remoteImageName, {force: true});

// Press the upload button.
cy.get('coral-dialog.is-open coral-dialog-footer [variant="primary"]').click();
cy.get('coral-dialog.is-open coral-dialog-footer [variant="primary"]').click({force: true});

// Wait for the /content/dam.completeUpload.json POST to complete before polling for the asset
cy.wait(['@completeupload'], { responseTimeout: 10000 });

// Wait until Asset exists
cy.waitUntil(() => cy.AEMPathExists(Cypress.env('AEM_AUTHOR_URL'), imagePath), {errorMsg: `asset ${imagePath} should exist`})
cy.waitUntil(() => cy.AEMPathExists(Cypress.env('AEM_AUTHOR_URL'), imagePath), {
errorMsg: `asset ${imagePath} should exist`,
timeout: 15000,
interval: 1000
});

// Wait before deletion as immediate deletion may fail
cy.wait(1000)
cy.wait(3000)

// Delete Asset
cy.AEMDeleteAsset(imagePath);

// Wait until Asset does not exist anymore
cy.waitUntil(() => cy.AEMPathExists(Cypress.env('AEM_AUTHOR_URL'), imagePath).then(result => !result), {errorMsg: `asset ${imagePath} should not exist`})
cy.waitUntil(() => cy.AEMPathExists(Cypress.env('AEM_AUTHOR_URL'), imagePath).then(result => !result), {
errorMsg: `asset ${imagePath} should not exist`,
timeout: 15000,
interval: 1000
});
});
})
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ Cypress.Commands.add('AEMPathExists', function (baseUrl, path) {
failOnStatusCode: false,
})
.then(response => {
return (response.status == 200)
return (response.status === 200)
});
})

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,10 @@
*/

import './commands'
require('cypress-terminal-report/src/installLogsCollector')({
xhr: {
printHeaderData: false,
printRequestData: false,
},
debug: true
});
Empty file.
Loading

0 comments on commit a3ee19f

Please sign in to comment.