Bug fixes
This commit is contained in:
parent
b5e5b5bd6b
commit
57479aaf76
|
@ -133,6 +133,7 @@ describe('Edit pay method path', () => {
|
|||
|
||||
it(`should add the IBAN`, done => {
|
||||
nightmare
|
||||
.clearInput(selectors.payMethod.IBANInput)
|
||||
.type(selectors.payMethod.IBANInput, 'ES91 2100 0418 4502 0005 1332')
|
||||
.waitToClick(selectors.payMethod.saveButton)
|
||||
.waitToClick(selectors.payMethod.cancelNotificationButton)
|
||||
|
|
|
@ -250,8 +250,8 @@ describe('Edit addresses path', () => {
|
|||
nightmare
|
||||
.waitForSnackbarReset()
|
||||
.waitToClick(selectors.addresses.addressesButton)
|
||||
.wait(selectors.addresses.isDefaultAddress)
|
||||
.getInnerText(selectors.addresses.isDefaultAddress)
|
||||
.wait(selectors.addresses.defaultAddress)
|
||||
.getInnerText(selectors.addresses.defaultAddress)
|
||||
.then(result => {
|
||||
expect(result).toContain('320 Park Avenue New York');
|
||||
done();
|
||||
|
@ -263,8 +263,8 @@ describe('Edit addresses path', () => {
|
|||
nightmare
|
||||
.waitForSnackbarReset()
|
||||
.waitToClick(selectors.addresses.secondMakeDefaultStar)
|
||||
.waitForTextInElement(selectors.addresses.isDefaultAddress, 'Somewhere in Thailand')
|
||||
.getInnerText(selectors.addresses.isDefaultAddress)
|
||||
.waitForTextInElement(selectors.addresses.defaultAddress, 'Somewhere in Thailand')
|
||||
.getInnerText(selectors.addresses.defaultAddress)
|
||||
.then(result => {
|
||||
expect(result).toContain('Somewhere in Thailand');
|
||||
done();
|
||||
|
@ -274,7 +274,7 @@ describe('Edit addresses path', () => {
|
|||
|
||||
it(`should click on the edit icon of the default address`, done => {
|
||||
nightmare
|
||||
.waitForTextInElement(selectors.addresses.isDefaultAddress, 'Somewhere in Thailand')
|
||||
.waitForTextInElement(selectors.addresses.defaultAddress, 'Somewhere in Thailand')
|
||||
.waitToClick(selectors.addresses.firstEditButton)
|
||||
.waitForURL('/edit')
|
||||
.url()
|
||||
|
|
68
gulpfile.js
68
gulpfile.js
|
@ -40,15 +40,15 @@ gulp.task('services', callback => {
|
|||
exec(command, (err, stdout, stderr) => {
|
||||
let isNotRunning = !stdout.includes('running');
|
||||
if (isNotRunning) {
|
||||
runSequence('docker', 'waitForMySQL', 'run-services');
|
||||
runSequence('docker-wait', 'services-run', callback);
|
||||
} else {
|
||||
runSequence('run-services');
|
||||
runSequence('services-run', callback);
|
||||
}
|
||||
callback(err);
|
||||
});
|
||||
});
|
||||
|
||||
gulp.task('run-services', ['nginx'], () => {
|
||||
gulp.task('services-run', ['nginx'], () => {
|
||||
const servicesPath = './services/';
|
||||
const services = fs.readdirSync(servicesPath);
|
||||
services.splice(services.indexOf('loopback'), 1);
|
||||
|
@ -63,11 +63,11 @@ gulp.task('test', callback => {
|
|||
return require('./services_tests').start();
|
||||
});
|
||||
|
||||
gulp.task('e2e', callback => {
|
||||
runSequence('docker', 'waitForMySQL', 'run-e2e', callback);
|
||||
gulp.task('e2e', ['docker-wait'], callback => {
|
||||
return gulp.start('e2e-run');
|
||||
});
|
||||
|
||||
gulp.task('run-e2e', callback => {
|
||||
gulp.task('e2e-run', callback => {
|
||||
gulp.src('./e2e_tests.js')
|
||||
.pipe(jasmine({reporter: 'none'}));
|
||||
});
|
||||
|
@ -190,37 +190,11 @@ gulp.task('watch', function() {
|
|||
// E2E tests
|
||||
|
||||
gulp.task('docker', callback => {
|
||||
runSequence('deleteDockerDb', 'deleteDockerImageDb', 'buildDockerDb', 'runDockerDb', callback);
|
||||
runSequence('docker-delete', 'docker-delete-image', 'docker-build', 'docker-run', callback);
|
||||
});
|
||||
|
||||
gulp.task('runDockerDb', callback => {
|
||||
exec('docker run -d --name dblocal -p 3306:3306 dblocal', (err, stdout, stderr) => {
|
||||
setTimeout(() => {
|
||||
callback(err);
|
||||
}, 15000);
|
||||
});
|
||||
});
|
||||
|
||||
gulp.task('buildDockerDb', callback => {
|
||||
exec('docker build -t dblocal:latest ./services/db', (err, stdout, stderr) => {
|
||||
callback(err);
|
||||
});
|
||||
});
|
||||
|
||||
gulp.task('deleteDockerImageDb', callback => {
|
||||
exec('docker rmi dblocal:latest', (err, stdout, stderr) => {
|
||||
callback(err = null);
|
||||
});
|
||||
});
|
||||
|
||||
gulp.task('deleteDockerDb', callback => {
|
||||
exec('docker stop dblocal && docker wait dblocal && docker rm -f dblocal', (err, stdout, stderr) => {
|
||||
callback(err = null);
|
||||
});
|
||||
});
|
||||
|
||||
gulp.task('waitForMySQL', callback => {
|
||||
let maxInterval = 30000;
|
||||
gulp.task('docker-wait', ['docker'], callback => {
|
||||
let maxInterval = 30 * 60000;
|
||||
let interval = 1000;
|
||||
let timer = 0;
|
||||
console.log('Waiting for MySQL init process...');
|
||||
|
@ -239,3 +213,27 @@ gulp.task('waitForMySQL', callback => {
|
|||
}
|
||||
}, interval);
|
||||
});
|
||||
|
||||
gulp.task('docker-run', callback => {
|
||||
exec('docker run -d --name dblocal -p 3306:3306 dblocal', (err, stdout, stderr) => {
|
||||
callback(err);
|
||||
});
|
||||
});
|
||||
|
||||
gulp.task('docker-build', callback => {
|
||||
exec('docker build -t dblocal:latest ./services/db', (err, stdout, stderr) => {
|
||||
callback(err);
|
||||
});
|
||||
});
|
||||
|
||||
gulp.task('docker-delete-image', callback => {
|
||||
exec('docker rmi dblocal:latest', (err, stdout, stderr) => {
|
||||
callback(err);
|
||||
});
|
||||
});
|
||||
|
||||
gulp.task('docker-delete', callback => {
|
||||
exec('docker stop dblocal && docker wait dblocal && docker rm -f dblocal', (err, stdout, stderr) => {
|
||||
callback(err);
|
||||
});
|
||||
});
|
||||
|
|
|
@ -1 +1 @@
|
|||
conect.ini
|
||||
connect.ini
|
||||
|
|
148149
services/db/01-structure.sql
148149
services/db/01-structure.sql
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,5 @@
|
|||
[client]
|
||||
host=localhost
|
||||
port=3306
|
||||
user=root
|
||||
password=
|
|
@ -1,5 +1,5 @@
|
|||
|
||||
mysqldump --defaults-extra-file=conect.ini --default-character-set=utf8 --no-data --triggers --routines --events --databases account util vn2008 vn edi bs bi pbx cache salix vncontrol hedera > 01-structure.sql
|
||||
mysqldump --defaults-extra-file=connect.ini --default-character-set=utf8 --no-data --triggers --routines --events --databases account util vn2008 vn edi bs bi pbx cache salix vncontrol hedera > 01-structure.sql
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -3,5 +3,6 @@
|
|||
"You are not allowed to change the credit": "No tienes privilegios para modificar el crédito",
|
||||
"Unable to mark the equivalence surcharge": "No se puede marcar el recargo de equivalencia",
|
||||
"The default consignee can not be unchecked": "No se puede desmarcar el consignatario predeterminado",
|
||||
"Unable to default a disabled consignee": "No se puede poner predeterminado un consignatario desactivado"
|
||||
"Unable to default a disabled consignee": "No se puede poner predeterminado un consignatario desactivado",
|
||||
"El método de pago seleccionado requiere que se especifique el IBAN": "El método de pago seleccionado requiere que se especifique el IBAN"
|
||||
}
|
Loading…
Reference in New Issue