Skip to content

Commit

Permalink
test: update development tslint version (#5936)
Browse files Browse the repository at this point in the history
Also fixes any encountered errors.

This only changes the version used for the CLI's development.  The project template version of tslint cannot be updated until codelyzer supports the latest version. ([codelyzer tracking issue](mgechev/codelyzer#281))
  • Loading branch information
clydin authored and filipesilva committed May 4, 2017
1 parent 2bf5c96 commit de8336d
Show file tree
Hide file tree
Showing 11 changed files with 15 additions and 11 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@
"through": "^2.3.6",
"tree-kill": "^1.0.0",
"ts-node": "^2.0.0",
"tslint": "^4.0.2"
"tslint": "^5.1.0"
},
"optionalDependencies": {
"node-sass": "^4.3.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/@angular/cli/lib/ast-tools/route-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ export function insertImport(fileToEdit: string, symbolName: string,
fallbackPos,
ts.SyntaxKind.StringLiteral
);
};
}

/**
* Inserts a path to the new route into src/routes.ts if it doesn't exist
Expand Down
2 changes: 1 addition & 1 deletion packages/@angular/cli/models/webpack-configs/typescript.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ export const getAotConfig = function(wco: WebpackConfigOptions) {
// Fallback to exclude spec files from AoT compilation on projects using a shared tsconfig.
if (testTsConfigPath === tsConfigPath) {
let exclude = [ '**/*.spec.ts' ];
if (appConfig.test) { exclude.push(path.join(projectRoot, appConfig.root, appConfig.test)); };
if (appConfig.test) { exclude.push(path.join(projectRoot, appConfig.root, appConfig.test)); }
pluginOptions.exclude = exclude;
}

Expand Down
6 changes: 4 additions & 2 deletions packages/@angular/cli/utilities/app-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ export function getAppFromConfig(nameOrIndex?: String) {
} else {
return apps[0];
}
throw new SilentError(chalk.red(oneLine`Unable to find app with name or index.
Make you have proper apps configuration in \`.angular-cli.json\``));
throw new SilentError(chalk.red(oneLine`
Unable to find app with name or index.
Verify the configuration in \`.angular-cli.json\`
`));
}
2 changes: 1 addition & 1 deletion packages/@angular/cli/utilities/dynamic-path-parser.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,4 +61,4 @@ export function dynamicPathParser(project: any, entityName: string, appConfig: a
parsedPath.dir = parsedPath.dir === path.sep ? '' : parsedPath.dir;

return { ...parsedPath, appRoot, sourceDir };
};
}
2 changes: 1 addition & 1 deletion packages/@angular/cli/utilities/find-parent-module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,4 @@ export default function findParentModule(
}

throw new SilentError('No module files found');
};
}
2 changes: 1 addition & 1 deletion packages/@angular/cli/utilities/get-dependent-files.ts
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ export function getDependentFiles(fileName: string, rootPath: string): Promise<M
});
if (tempModuleSpecifiers.length > 0) {
relevantFiles[filePath] = tempModuleSpecifiers;
};
}
});
return relevantFiles;
}));
Expand Down
2 changes: 1 addition & 1 deletion packages/@angular/cli/utilities/module-resolver.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ export class ModuleResolver {
let changeText = path.relative(fileDir, path.join(this.newFilePath, componentName));
if (changeText.length > 0 && changeText.charAt(0) !== '.') {
changeText = `.${path.sep}${changeText}`;
};
}
let position = specifier.end - specifier.specifierText.length;
return new ReplaceChange(file, position - 1, specifier.specifierText, changeText);
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,4 +53,4 @@ export class PrerenderWebpackPlugin {
delete require.cache[key];
});
}
};
}
2 changes: 2 additions & 0 deletions packages/@ngtools/json-schema/src/schema-tree.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ describe('@ngtools/json-schema', () => {

it('works', () => {
const proto: any = Object.create(null);
// tslint:disable-next-line
new RootSchemaTreeNode(proto, {
value: valueJson,
schema: schemaJson
Expand Down Expand Up @@ -47,6 +48,7 @@ describe('@ngtools/json-schema', () => {

it('works', () => {
const proto: any = Object.create(null);
// tslint:disable-next-line
new RootSchemaTreeNode(proto, {
value: valueJson,
schema: schemaJson
Expand Down
2 changes: 1 addition & 1 deletion packages/@ngtools/json-schema/src/schema-tree.ts
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ export abstract class SchemaTreeNode<T> implements SchemaNode {
throw new MissingImplementationError();
}
throw new SettingReadOnlyPropertyError();
};
}
isCompatible(_v: any) { return false; }

abstract serialize(serializer: Serializer): void;
Expand Down

0 comments on commit de8336d

Please sign in to comment.