Skip to content

Commit

Permalink
Updated the README.md file
Browse files Browse the repository at this point in the history
  • Loading branch information
Robinyo committed Nov 26, 2017
1 parent 73bf574 commit a7d0d0c
Show file tree
Hide file tree
Showing 6 changed files with 163 additions and 9 deletions.
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -358,14 +358,19 @@ Updated `tsconfig.ng-cli.json` in `compilerOptions`:
}
```

Updated `angular-cli.json` in `apps`:
Updated `.angular-cli.json` in `apps`:
```json
"environments": {
"dev": "environments/environment.dev.ts",
"prod": "environments/environment.ts"
}
```

Updated `/src/tsconfig.spec.json` in `compilerOptions`:
```json
"baseUrl": "./",
```

### Jasmine

The [Jasmine test framework](https://jasmine.github.io/2.4/introduction.html) provides everything needed to write basic tests.
Expand Down
41 changes: 41 additions & 0 deletions protractor.conf.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
exports.config = {
allScriptsTimeout: 11000,
specs: [
'./e2e/**/*.e2e-spec.ts'
],
capabilities: {
'browserName': 'chrome',
chromeOptions: {
args: ['--no-sandbox']
}
},
directConnect: true,
baseUrl: 'http://localhost:4200/',
framework: 'jasmine',
jasmineNodeOpts: {
showColors: true,
defaultTimeoutInterval: 30000,
print: function() {}
},
useAllAngular2AppRoots: true,
beforeLaunch: function() {
require('ts-node').register({
project: 'e2e/tsconfig.e2e.json'
});

require('connect')().use(require('serve-static')('www')).listen(4200);
},
onPrepare() {
var jasmineReporters = require('jasmine-reporters');
jasmine.getEnv().addReporter(new jasmineReporters.TerminalReporter({
verbosity: 3,
color: true,
showStack: true
}));
jasmine.getEnv().addReporter(new jasmineReporters.JUnitXmlReporter({
savePath: process.env.JUNIT_REPORT_PATH,
outputFile: process.env.JUNIT_REPORT_NAME,
consolidateAll: true
}));
}
};
3 changes: 2 additions & 1 deletion src/pages/sign-in/sign-in.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@ import { ComponentFixture, async } from '@angular/core/testing';

import { TestUtils } from '../../test';

import { SignInPage } from './sign-in';
// import { SignInPage } from './sign-in';
import { SignInPage } from '@pages/sign-in/sign-in';

let fixture: ComponentFixture<SignInPage> = null;
let instance: any = null;
Expand Down
4 changes: 2 additions & 2 deletions src/tsconfig.spec.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
"extends": "../tsconfig.ng-cli.json",
"compilerOptions": {
"outDir": "../out-tsc/spec",
"outDir": "../dist/out-tsc/spec",
"module": "commonjs",
"target": "es5",
"baseUrl": "",
"baseUrl": "./",
"types": [
"jasmine",
"node"
Expand Down
3 changes: 3 additions & 0 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@
"typeRoots": [
"../node_modules/@types"
],
"types": [
"jasmine"
],
"baseUrl": "./src",
"paths": {
"@app/*": [ "app/*" ],
Expand Down
114 changes: 109 additions & 5 deletions tslint.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,112 @@
{
"rules": {
"no-duplicate-variable": true
},
"rulesDirectory": [
"node_modules/tslint-eslint-rules/dist/rules"
]
"align": [
true,
"parameters",
"arguments",
"statements"
],
"ban": false,
"class-name": true,
"comment-format": [
true,
"check-space"
],
"curly": false,
"eofline": true,
"forin": false,
"indent": [
true,
"spaces"
],
"interface-name": false,
"jsdoc-format": true,
"label-position": true,
"max-line-length": [
true,
180
],
"member-access": true,
"member-ordering": [false],
"no-any": false,
"no-arg": true,
"no-bitwise": true,
"no-conditional-assignment": true,
"no-consecutive-blank-lines": true,
"no-console": [false],
"no-construct": false,
"no-debugger": true,
"no-duplicate-variable": true,
"no-empty": true,
"no-eval": true,
"no-inferrable-types": false,
"no-internal-module": true,
"no-require-imports": false,
"no-shadowed-variable": true,
"no-string-literal": false,
"no-switch-case-fall-through": true,
"no-trailing-whitespace": true,
"no-unused-variable": [
true,
"check-parameters",
{ "ignore-pattern": "^ng*|^on*" }
],
"no-use-before-declare": true,
"no-var-keyword": true,
"no-var-requires": true,
"object-literal-sort-keys": false,
"one-line": [
true,
"check-open-brace",
"check-whitespace"
],
"quotemark": [
true,
"single",
"avoid-escape"
],
"radix": false,
"semicolon": true,
"switch-default": false,
"trailing-comma": [
true,
{
"multiline": "always",
"singleline": "never"
}
],
"triple-equals": [true],
"typedef": [
true,
"call-signature",
"parameter",
"property-declaration",
"variable-declaration",
"member-variable-declaration"
],
"typedef-whitespace": [
true,
{
"call-signature": "nospace",
"index-signature": "nospace",
"parameter": "nospace",
"property-declaration": "nospace",
"variable-declaration": "nospace"
}
],
"variable-name": [
true,
"check-format",
"allow-leading-underscore",
"ban-keywords"
],
"whitespace": [
true,
"check-branch",
"check-decl",
"check-operator",
"check-separator",
"check-type"
]
}
}

0 comments on commit a7d0d0c

Please sign in to comment.