Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/e2e-testing #42

Merged
merged 26 commits into from
Dec 14, 2017
Merged

Feature/e2e-testing #42

merged 26 commits into from
Dec 14, 2017

Conversation

hirsch88
Copy link
Member

No description provided.

@hirsch88 hirsch88 self-assigned this Dec 12, 2017
@hirsch88 hirsch88 mentioned this pull request Dec 12, 2017
@@ -343,7 +339,7 @@ export class CreateUsers implements SeedsInterface {
public async seed(factory: FactoryInterface): Promise<any> {
await factory
.get(User, 'admin')
.create(1);
.create();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be nice when we could use create(10) and create() so we don't need an additional method createMany(x).

'nps test.e2e.pretest',
'nps test.e2e.run'
),
pretest: 'tslint -c ./tslint.json -t stylish ./test/e2e/**/*.ts',
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we refactor this command to be more generic and pass a parameter ./test/e2e/**/*.ts so we can centralise the tslint logic.

@@ -1,10 +1,14 @@
import { FactoryInterface } from './FactoryInterface';
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Refactor file name to SeedInterfaces.ts as the file exports more than one.

describe('/api/users', () => {

// -------------------------------------------------------------------------
// Tear up
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thats called Setup up.

@@ -0,0 +1,15 @@
import { createDatabaseConnection } from './../../integration/utils/database';
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably we should isolate integration tests from e2d tests?

@@ -0,0 +1,38 @@
import { Application } from 'express';
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's unused. Please fix your tslint or ts => https://palantir.github.io/tslint/rules/no-unused-variable/

@@ -0,0 +1,66 @@
import * as nock from 'nock';
import * as request from 'supertest';
import { Application } from 'express';
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's unused. Please fix your tslint or ts => https://palantir.github.io/tslint/rules/no-unused-variable/

import { monitorLoader } from './../../../src/loaders/monitorLoader';
import { homeLoader } from './../../../src/loaders/homeLoader';
import { typeormLoader } from '../utils/typeormLoader';
import { publicLoader } from './../../../src/loaders/publicLoader';
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's unused. Please fix your tslint or ts => https://palantir.github.io/tslint/rules/no-unused-variable/

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please check the whole file

import { monitorLoader } from './../../../src/loaders/monitorLoader';
import { homeLoader } from './../../../src/loaders/homeLoader';
import { typeormLoader } from '../utils/typeormLoader';
import { publicLoader } from './../../../src/loaders/publicLoader';
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please check the whole file

import { Connection } from 'typeorm/connection/Connection';
import { createConnection } from 'typeorm';
import { MicroframeworkSettings, MicroframeworkLoader } from 'microframework-w3tec';
import { env } from '../../../src/core/env';
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's unused. Please fix your tslint or ts => https://palantir.github.io/tslint/rules/no-unused-variable/

@hirsch88 hirsch88 merged commit 018cf87 into develop Dec 14, 2017
@hirsch88 hirsch88 deleted the feature/e2e branch December 18, 2017 19:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants