Skip to content

Commit 068bfbd

Browse files
jolelievrenicosomb
authored andcommitted
Add hummingbird theme as a native dependency in composer
1 parent cc81f8b commit 068bfbd

File tree

106 files changed

+388
-373
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

106 files changed

+388
-373
lines changed

Makefile

+3
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,9 @@ front-core: ## Building core theme assets
1919
front-classic: ## Building classic theme assets
2020
./tools/assets/build.sh front-classic
2121

22+
front-hummingbird: ## Building hummingbird theme assets
23+
./tools/assets/build.sh front-hummingbird
24+
2225
admin-default: ## Building admin default theme assets
2326
./tools/assets/build.sh admin-default
2427

composer.json

+5
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@
6969
"prestashop/graphnvd3": "^2",
7070
"prestashop/gridhtml": "^2",
7171
"prestashop/gsitemap": "^4",
72+
"prestashop/hummingbird": "dev-remove-env-config",
7273
"prestashop/pagesnotfound": "^2",
7374
"prestashop/productcomments": "^7.0",
7475
"prestashop/ps_apiresources": "dev-dev",
@@ -257,6 +258,10 @@
257258
"ps_apiresources": {
258259
"type": "vcs",
259260
"url": "https://github.com/PrestaShop/ps_apiresources.git"
261+
},
262+
"hummingbird": {
263+
"type": "vcs",
264+
"url": "https://github.com/nicosomb/hummingbird.git"
260265
}
261266
},
262267
"minimum-stability": "dev",

composer.lock

+40-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

tests/UI/campaigns/functional/BO/08_design/01_themeAndLogo/01_themeAndLogo/01_addNewTheme.ts

+18-18
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ describe('BO - Design - Theme & Logo : Add new theme', async () => {
2222
let browserContext: BrowserContext;
2323
let page: Page;
2424

25-
const urlTheme: string = 'https://github.com/PrestaShop/hummingbird/releases/download/v0.1.6/hummingbird.zip';
25+
const urlTheme: string = 'https://github.com/prestarocket-agence/classic-rocket/releases/download/3.1.0/classic-rocket.zip';
2626

2727
// before and after functions
2828
before(async function () {
@@ -36,7 +36,7 @@ describe('BO - Design - Theme & Logo : Add new theme', async () => {
3636
await Promise.all([
3737
utilsFile.deleteFile('theme.zip'),
3838
utilsFile.deleteFile('../../themes/theme.zip'),
39-
utilsFile.deleteFile('../../admin-dev/hummingbird.zip'),
39+
utilsFile.deleteFile('../../admin-dev/classic-rocket.zip'),
4040
]);
4141
});
4242

@@ -86,17 +86,17 @@ describe('BO - Design - Theme & Logo : Add new theme', async () => {
8686
expect(pageTitle).to.contains(themeAndLogoPage.pageTitle);
8787

8888
const numThemes = await themeAndLogoPage.getNumberOfThemes(page);
89-
expect(numThemes).to.eq(2);
89+
expect(numThemes).to.eq(3);
9090
});
9191

92-
it('should remove the theme Hummingbird', async function () {
93-
await testContext.addContextItem(this, 'testIdentifier', 'removeThemeHummingbird1', baseContext);
92+
it('should remove the theme classic-rocket', async function () {
93+
await testContext.addContextItem(this, 'testIdentifier', 'removeThemeClassicrocket1', baseContext);
9494

95-
const result = await themeAndLogoPage.removeTheme(page, 'hummingbird');
95+
const result = await themeAndLogoPage.removeTheme(page, 'classic-rocket');
9696
expect(result).to.eq(themeAndLogoPage.successfulDeleteMessage);
9797

9898
const numThemes = await themeAndLogoPage.getNumberOfThemes(page);
99-
expect(numThemes).to.eq(1);
99+
expect(numThemes).to.eq(2);
100100
});
101101
});
102102

@@ -110,7 +110,7 @@ describe('BO - Design - Theme & Logo : Add new theme', async () => {
110110
expect(pageTitle).to.contains(themeImportPage.pageTitle);
111111
});
112112

113-
it('should import from the web the Hummingbird theme', async function () {
113+
it('should import from the web the classic-rocket theme', async function () {
114114
await testContext.addContextItem(this, 'testIdentifier', 'importThemeFromWeb', baseContext);
115115

116116
await themeImportPage.importFromWeb(page, urlTheme);
@@ -119,17 +119,17 @@ describe('BO - Design - Theme & Logo : Add new theme', async () => {
119119
expect(pageTitle).to.contains(themeAndLogoPage.pageTitle);
120120

121121
const numThemes = await themeAndLogoPage.getNumberOfThemes(page);
122-
expect(numThemes).to.eq(2);
122+
expect(numThemes).to.eq(3);
123123
});
124124

125-
it('should remove the theme Hummingbird', async function () {
126-
await testContext.addContextItem(this, 'testIdentifier', 'removeThemeHummingbird2', baseContext);
125+
it('should remove the theme classic-rocket', async function () {
126+
await testContext.addContextItem(this, 'testIdentifier', 'removeThemeClassicrocket2', baseContext);
127127

128-
const result = await themeAndLogoPage.removeTheme(page, 'hummingbird');
128+
const result = await themeAndLogoPage.removeTheme(page, 'classic-rocket');
129129
expect(result).to.eq(themeAndLogoPage.successfulDeleteMessage);
130130

131131
const numThemes = await themeAndLogoPage.getNumberOfThemes(page);
132-
expect(numThemes).to.eq(1);
132+
expect(numThemes).to.eq(2);
133133
});
134134
});
135135

@@ -154,17 +154,17 @@ describe('BO - Design - Theme & Logo : Add new theme', async () => {
154154
expect(pageTitle).to.contains(themeAndLogoPage.pageTitle);
155155

156156
const numThemes = await themeAndLogoPage.getNumberOfThemes(page);
157-
expect(numThemes).to.eq(2);
157+
expect(numThemes).to.eq(3);
158158
});
159159

160-
it('should remove the theme Hummingbird', async function () {
161-
await testContext.addContextItem(this, 'testIdentifier', 'removeThemeHummingbird3', baseContext);
160+
it('should remove the theme classic-rocket', async function () {
161+
await testContext.addContextItem(this, 'testIdentifier', 'removeThemeClassicrocket3', baseContext);
162162

163-
const result = await themeAndLogoPage.removeTheme(page, 'hummingbird');
163+
const result = await themeAndLogoPage.removeTheme(page, 'classic-rocket');
164164
expect(result).to.eq(themeAndLogoPage.successfulDeleteMessage);
165165

166166
const numThemes = await themeAndLogoPage.getNumberOfThemes(page);
167-
expect(numThemes).to.eq(1);
167+
expect(numThemes).to.eq(2);
168168
});
169169
});
170170
});

tests/UI/campaigns/functional/BO/08_design/01_themeAndLogo/03_advancedCustomization/01_advancedCustomization.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ describe('BO - Design - Theme & Logo - Advanced Customization', async () => {
185185
it('should use the child theme', async function () {
186186
await testContext.addContextItem(this, 'testIdentifier', 'useChildTheme', baseContext);
187187

188-
const successResult = await themeAndLogoPage.useTheme(page);
188+
const successResult = await themeAndLogoPage.useTheme(page, 'child_classic');
189189
expect(successResult).to.be.equal(themeAndLogoPage.successfulUpdateMessage);
190190
});
191191

@@ -214,14 +214,14 @@ describe('BO - Design - Theme & Logo - Advanced Customization', async () => {
214214
it('should use the classic theme', async function () {
215215
await testContext.addContextItem(this, 'testIdentifier', 'useClassicTheme', baseContext);
216216

217-
const successResult = await themeAndLogoPage.useTheme(page);
217+
const successResult = await themeAndLogoPage.useTheme(page, 'classic');
218218
expect(successResult).to.be.equal(themeAndLogoPage.successfulUpdateMessage);
219219
});
220220

221221
it('should delete the child theme', async function () {
222222
await testContext.addContextItem(this, 'testIdentifier', 'deleteChildTheme', baseContext);
223223

224-
const successResult = await themeAndLogoPage.deleteTheme(page);
224+
const successResult = await themeAndLogoPage.deleteTheme(page, 'child_classic');
225225
expect(successResult).to.be.equal(themeAndLogoPage.successfulDeleteMessage);
226226
});
227227
});

tests/UI/campaigns/functional/BO/11_international/04_translations/01_modifyTranslation.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import testContext from '@utils/testContext';
33

44
// Import commonTests
55
import loginCommon from '@commonTests/BO/loginBO';
6-
import {installHummingbird, uninstallHummingbird} from '@commonTests/BO/design/hummingbird';
6+
import {enableHummingbird, disableHummingbird} from '@commonTests/BO/design/hummingbird';
77
import {setupSmtpConfigTest, resetSmtpConfigTest} from '@commonTests/BO/advancedParameters/smtp';
88

99
// Import BO pages
@@ -188,7 +188,7 @@ describe('BO - International - Translation : Modify translation', async () => {
188188
});
189189

190190
// Pre-condition : Install Hummingbird
191-
installHummingbird(`${baseContext}_preTest_2`);
191+
enableHummingbird(`${baseContext}_preTest_2`);
192192

193193
describe('Case 3 - Front office translations with hummingbird theme', async () => {
194194
it('should go back to BO', async function () {
@@ -270,7 +270,7 @@ describe('BO - International - Translation : Modify translation', async () => {
270270
});
271271

272272
// Post-condition : Uninstall Hummingbird
273-
uninstallHummingbird(`${baseContext}_postTest_1`);
273+
disableHummingbird(`${baseContext}_postTest_1`);
274274

275275
describe('Case 4 - Installed modules translations', async () => {
276276
it('should go back to BO', async function () {

tests/UI/campaigns/functional/BO/13_shopParameters/03_productSettings/02_productPage/02_displayAddToCartButton.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import testContext from '@utils/testContext';
33

44
// Import commonTests
55
import loginCommon from '@commonTests/BO/loginBO';
6-
import {installHummingbird, uninstallHummingbird} from '@commonTests/BO/design/hummingbird';
6+
import {enableHummingbird, disableHummingbird} from '@commonTests/BO/design/hummingbird';
77

88
// Import pages
99
// Import BO pages
@@ -25,7 +25,7 @@ describe('BO - Shop Parameters - Product Settings : Display add to cart button w
2525
let page: Page;
2626

2727
// Pre-condition : Install Hummingbird
28-
installHummingbird(`${baseContext}-preTest`);
28+
enableHummingbird(`${baseContext}-preTest`);
2929

3030
// before and after functions
3131
before(async function () {
@@ -104,5 +104,5 @@ describe('BO - Shop Parameters - Product Settings : Display add to cart button w
104104
});
105105

106106
// Post-condition : Uninstall Hummingbird
107-
uninstallHummingbird(`${baseContext}-postTest`);
107+
disableHummingbird(`${baseContext}-postTest`);
108108
});

tests/UI/campaigns/functional/FO/hummingbird/01_login/01_passwordReminder.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import testContext from '@utils/testContext';
55
import {setupSmtpConfigTest, resetSmtpConfigTest} from '@commonTests/BO/advancedParameters/smtp';
66
import {deleteCustomerTest} from '@commonTests/BO/customers/customer';
77
import createAccountTest from '@commonTests/FO/hummingbird/account';
8-
import {installHummingbird, uninstallHummingbird} from '@commonTests/BO/design/hummingbird';
8+
import {enableHummingbird, disableHummingbird} from '@commonTests/BO/design/hummingbird';
99

1010
// Import FO pages
1111
import homePage from '@pages/FO/hummingbird/home';
@@ -56,7 +56,7 @@ describe('FO - Login : Password reminder', async () => {
5656
setupSmtpConfigTest(`${baseContext}_preTest_1`);
5757

5858
// Pre-condition : Install Hummingbird
59-
installHummingbird(`${baseContext}_preTest_2`);
59+
enableHummingbird(`${baseContext}_preTest_2`);
6060

6161
// Pre-condition : Create new customer on FO
6262
createAccountTest(customerData, `${baseContext}_preTest_3`);
@@ -208,5 +208,5 @@ describe('FO - Login : Password reminder', async () => {
208208
resetSmtpConfigTest(`${baseContext}_postTest_2`);
209209

210210
// Post-condition : Uninstall Hummingbird
211-
uninstallHummingbird(`${baseContext}_postTest_3`);
211+
disableHummingbird(`${baseContext}_postTest_3`);
212212
});

tests/UI/campaigns/functional/FO/hummingbird/01_login/02_login.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
import testContext from '@utils/testContext';
33

44
// Import commonTests
5-
import {installHummingbird, uninstallHummingbird} from '@commonTests/BO/design/hummingbird';
5+
import {enableHummingbird, disableHummingbird} from '@commonTests/BO/design/hummingbird';
66

77
// Import FO pages
88
import homePage from '@pages/FO/hummingbird/home';
@@ -28,7 +28,7 @@ describe('FO - Login : Login in FO', async () => {
2828
const thirdCredentialsData: FakerCustomer = new FakerCustomer({email: dataCustomers.johnDoe.email});
2929

3030
// Pre-condition : Install Hummingbird
31-
installHummingbird(`${baseContext}_preTest_1`);
31+
enableHummingbird(`${baseContext}_preTest_1`);
3232

3333
// before and after functions
3434
before(async function () {
@@ -114,5 +114,5 @@ describe('FO - Login : Login in FO', async () => {
114114
});
115115

116116
// Post-condition : Uninstall Hummingbird
117-
uninstallHummingbird(`${baseContext}_postTest_2`);
117+
disableHummingbird(`${baseContext}_postTest_2`);
118118
});

tests/UI/campaigns/functional/FO/hummingbird/01_login/03_logout.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
import testContext from '@utils/testContext';
33

44
// Import commonTests
5-
import {installHummingbird, uninstallHummingbird} from '@commonTests/BO/design/hummingbird';
5+
import {enableHummingbird, disableHummingbird} from '@commonTests/BO/design/hummingbird';
66

77
// Import FO pages
88
import homePage from '@pages/FO/hummingbird/home';
@@ -24,7 +24,7 @@ describe('FO - Login : Logout from FO', async () => {
2424
let page: Page;
2525

2626
// Pre-condition : Install Hummingbird
27-
installHummingbird(`${baseContext}_preTest_1`);
27+
enableHummingbird(`${baseContext}_preTest_1`);
2828

2929
// before and after functions
3030
before(async function () {
@@ -103,5 +103,5 @@ describe('FO - Login : Logout from FO', async () => {
103103
});
104104

105105
// Post-condition : Uninstall Hummingbird
106-
uninstallHummingbird(`${baseContext}_postTest_2`);
106+
disableHummingbird(`${baseContext}_postTest_2`);
107107
});

tests/UI/campaigns/functional/FO/hummingbird/01_login/04_createAccount.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import testContext from '@utils/testContext';
33

44
// Import commonTests
55
import {deleteCustomerTest} from '@commonTests/BO/customers/customer';
6-
import {installHummingbird, uninstallHummingbird} from '@commonTests/BO/design/hummingbird';
6+
import {enableHummingbird, disableHummingbird} from '@commonTests/BO/design/hummingbird';
77

88
// Import FO pages
99
import homePage from '@pages/FO/hummingbird/home';
@@ -27,7 +27,7 @@ describe('FO - Login : Create account', async () => {
2727
const customerData: FakerCustomer = new FakerCustomer();
2828

2929
// Pre-condition : Install Hummingbird
30-
installHummingbird(`${baseContext}_preTest_1`);
30+
enableHummingbird(`${baseContext}_preTest_1`);
3131

3232
// before and after functions
3333
before(async function () {
@@ -97,5 +97,5 @@ describe('FO - Login : Create account', async () => {
9797
deleteCustomerTest(customerData, `${baseContext}_postTest_1`);
9898

9999
// Post-condition : Uninstall Hummingbird
100-
uninstallHummingbird(`${baseContext}_postTest_2`);
100+
disableHummingbird(`${baseContext}_postTest_2`);
101101
});

tests/UI/campaigns/functional/FO/hummingbird/02_headerAndFooter/01_checkLinksInHeader.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
import testContext from '@utils/testContext';
33

44
// Import commonTests
5-
import {installHummingbird, uninstallHummingbird} from '@commonTests/BO/design/hummingbird';
5+
import {enableHummingbird, disableHummingbird} from '@commonTests/BO/design/hummingbird';
66

77
// Import FO pages
88
import cartPage from '@pages/FO/hummingbird/cart';
@@ -38,7 +38,7 @@ describe('FO - Header and Footer : Check links in header page', async () => {
3838
let page: Page;
3939

4040
// Pre-condition : Install Hummingbird
41-
installHummingbird(`${baseContext}_preTest_1`);
41+
enableHummingbird(`${baseContext}_preTest_1`);
4242

4343
describe('Check links in header page', async () => {
4444
// before and after functions
@@ -159,5 +159,5 @@ describe('FO - Header and Footer : Check links in header page', async () => {
159159
});
160160

161161
// Post-condition : Uninstall Hummingbird
162-
uninstallHummingbird(`${baseContext}_postTest_1`);
162+
disableHummingbird(`${baseContext}_postTest_1`);
163163
});

0 commit comments

Comments
 (0)