fix compiler error

This commit is contained in:
Umed Khudoiberdiev 2018-01-17 14:41:08 +05:00
parent b8a5b09152
commit f1399ee312
3 changed files with 6 additions and 11 deletions

View File

@ -361,8 +361,8 @@ export class Gulpfile {
@SequenceTask()
tests() {
return [
"compile",
"tslint",
"coveragePre",
"runTests",
"coveragePost",
"coverageRemap"
];
@ -384,14 +384,6 @@ export class Gulpfile {
];
}
/**
* Compiles the code and runs only mocha tests.
*/
@SequenceTask()
mocha() {
return ["compile", "quickTests"];
}
// -------------------------------------------------------------------------
// CI tasks
// -------------------------------------------------------------------------

View File

@ -1622,6 +1622,9 @@ export class SelectQueryBuilder<Entity> extends QueryBuilder<Entity> implements
// if user used partial selection and did not select some primary columns which are required to be selected
// we select those primary columns and mark them as "virtual". Later virtual column values will be removed from final entity
// to make entity contain exactly what user selected
// if (columns.length === 0) // however not in the case when nothing (even partial) was selected from this target (for example joins without selection)
// return [];
const nonSelectedPrimaryColumns = this.expressionMap.queryEntity ? metadata.primaryColumns.filter(primaryColumn => columns.indexOf(primaryColumn) === -1) : [];
const allColumns = [...columns, ...nonSelectedPrimaryColumns];

View File

@ -22,7 +22,7 @@ describe("github issues > #1369 EntitySubscriber not firing events on abstract c
entity.position = "Regional Manager";
await connection.manager.save(entity);
const foundEntity = await connection.manager.findOneById(ConcreteEntity, 1);
const foundEntity = await connection.manager.findOne(ConcreteEntity, 1);
expect(foundEntity).to.not.be.undefined;
const assertObject = Object.assign({}, foundEntity);