Skip to content
Snippets Groups Projects
Commit 7c07e634 authored by jvfpw18's avatar jvfpw18
Browse files

Merge branch 'homologa' of gitlab.c3sl.ufpr.br:simcaq/simcaq-node into homologa

parents 7ba60eb4 bd8f24dc
No related branches found
No related tags found
1 merge request!257V1.14.0
Pipeline #23301 failed
......@@ -10,23 +10,34 @@ variables:
MONGO_URI: 'mongodb://mongo/app_name'
NODE_ENV: 'test'
#run_tests:
# stage: test
# before_script:
# - node -v
# - npm install --global gulp gulp-cli babel babel-cli babel-core babel-register mocha gulp-mocha #gulp-eslint
# - npm install
# script:
# - ping -W1 -c1 mongo
# - sed -i -e 's/false/true/g' config.json
# - gulp build
# - gulp test
# tags:
# - node
regression_tests:
stage: test
before_script:
- node -v
- npm install --global gulp gulp-cli babel babel-cli babel-core babel-register mocha gulp-mocha gulp-eslint
- npm install
- gulp build && gulp &
- curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
- python get-pip.py
run_tests:
stage: test
- sleep 60
script:
- git clone https://gitlab.c3sl.ufpr.br/simcaq/lde-api-regression-test.git
- ping -W1 -c1 mongo
- sed -i -e 's/false/true/g' config.json
- gulp build
- gulp test
- cd lde-api-regression-test
- pip install -r requirements.txt
- python regression_test.py --compare
- python manage.py compare --verbose
tags:
- node
......@@ -72,7 +72,7 @@ module.exports = function addMissing(rqf) {
}
if (dimsValues[rqfName].indexOf(r[rqfName]) === -1) {
if (['school', 'city', 'state', 'arrangement'].includes(dim)) { // those should be ordered by its name
if (['school', 'arrangement'].includes(dim)) { // those should be ordered by its name
let namePosition = binarySearch(r[secondaryRqfName], dimsNames[secondaryRqfName], 0, dimsNames[secondaryRqfName].length) // find the position of the name in alphabetical order and keep the names vector ordered
dimsValues[rqfName].splice(namePosition.pos, 0, r[rqfName]);
dimsNames[secondaryRqfName].splice(namePosition.pos, 0, r[secondaryRqfName]);
......
......@@ -241,7 +241,7 @@ rqf.addField({
}).addValue({
name: 'region',
table: 'localoferta_ens_superior',
tableField: ['nome_regiao_curso', 'cod_regiao_curso'],
tableField: ['nome_regiao', 'cod_regiao'],
resultField: ['region_name', 'region_id'],
where: {
relation: '=',
......@@ -257,7 +257,7 @@ rqf.addField({
}).addValue({
name: 'state',
table: 'localoferta_ens_superior',
tableField: ['sigla_uf', 'cod_uf'],
tableField: ['sigla_uf_t', 'cod_uf_t'],
resultField: ['state_name', 'state_id'],
where: {
relation: '=',
......@@ -273,7 +273,7 @@ rqf.addField({
}).addValue({
name: 'city',
table: 'localoferta_ens_superior',
tableField: ['cod_municipio', 'nome_municipio'],
tableField: ['cod_municipio_t', 'nome_municipio_t'],
resultField: ['city_id', 'city_name'],
where: {
relation: '=',
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment