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

Add test to sonar.ts #154

Merged
merged 1 commit into from
Apr 21, 2017
Merged

Add test to sonar.ts #154

merged 1 commit into from
Apr 21, 2017

Conversation

sarvaje
Copy link
Contributor

@sarvaje sarvaje commented Apr 20, 2017

Fix how we load plugins


Fix #5

@molant molant requested a review from alrra April 21, 2017 03:09
@molant molant self-assigned this Apr 21, 2017
@molant molant self-requested a review April 21, 2017 03:15
@molant molant removed their assignment Apr 21, 2017
t.false(t.context.resourceLoader.getRules.called);
});

test('If conflig.plugins is an array we should create just those plugins', (t) => {
Copy link
Contributor

Choose a reason for hiding this comment

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

config

t.is(t.context.eventemitter.prototype.on.args[2][0], 'fetch::error');
});

test('If conflig.rules is an array of ids we should create just those rules', (t) => {
Copy link
Contributor

Choose a reason for hiding this comment

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

config

t.is(sonarObject.pageContent, html);
});

test.serial('pageHeaders should return the HTML', async (t) => {
Copy link
Contributor

Choose a reason for hiding this comment

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

should return the page's response headers


import test from 'ava';
import * as sinon from 'sinon';
import * as proxyquire from 'proxyquire';
Copy link
Contributor

Choose a reason for hiding this comment

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

import * as proxyquire from 'proxyquire';
import * as sinon from 'sinon';
import test from 'ava';

Fix how plugins are loaded
Activate eol-last in eslint rules

--------------------------
Fix #5
@sarvaje
Copy link
Contributor Author

sarvaje commented Apr 21, 2017

@alrra @molant I have just activate the rule eol-last in the eslint configuration file, so @alrra won't need to fix it more hehehehe :P

@molant molant merged commit a754cbd into webhintio:master Apr 21, 2017
@alrra
Copy link
Contributor

alrra commented Apr 24, 2017

I have just activate the rule eol-last in the eslint configuration file, so @alrra won't need to fix it more hehehehe :P

Haha

Note: You can also make your text editor/IDE take into account the properties from the .editorconfig file. That way, the final newline will be added automatically (even to non .js/.ts files).

@sarvaje
Copy link
Contributor Author

sarvaje commented Apr 24, 2017

@alrra I thought that vscode took int account the .editorconfig... I've just installed a plugin to use it :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants