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

Unit test linting #3490

Merged

Conversation

pagarwal123
Copy link

Files updated for videojs-standard v5:

button.test.js
clickable-component.test.js
close-button.test.js
component.test.js
controls.test.js
events.test.js
extend.test.js
menu.test.js
modal-dialog.test.js
player.test.js

Requirements Checklist

  • Feature implemented / Bug fixed
  • Reviewed by Two Core Contributors

var parent, options;
QUnit.test('should allows setting child options at the parent options level', function() {
let parent;
let options;
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 combine this declaration and the assignment on line 189? let options = {

@@ -686,31 +711,31 @@ test('should emit a tap event', function(){
browser.TOUCH_ENABLED = origTouch;
});

test('should provide timeout methods that automatically get cleared on component disposal', function() {
expect(4);
QUnit.test('should provide timeout methods that automatically get cleared on component disposal',
Copy link
Contributor

Choose a reason for hiding this comment

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

you can put the function back on this line, we are going to work on ignoring the length of unit test name lines

Copy link
Member

Choose a reason for hiding this comment

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

Yeah, good idea. We can roll back the line length changes if we want.


player.tech_['featuresVolumeControl'] = true;
player.tech_.featuresVolumeControl = true;
for (i = 0; i < listeners.length; i++) {
Copy link
Contributor

Choose a reason for hiding this comment

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

take the let i from the top of this function and instead put it in this for statement for (let i = 0;...

Copy link
Member

Choose a reason for hiding this comment

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

and on line 66 as well.

@brandonocasey
Copy link
Contributor

LGTM other than the some minor comments and some QUnit. prefixes in a few files

comp1.off = function(){ throw 'Comp1 off called'; };
QUnit.equal(listenerFired, 0, 'listener was removed when this component was disposed first');
comp1.off = function() {
throw new Error('Comp1 off called');
Copy link
Member

Choose a reason for hiding this comment

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

Thanks for making this a new Error!

Copy link
Author

Choose a reason for hiding this comment

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

👍

@gkatsev
Copy link
Member

gkatsev commented Aug 3, 2016

almost there!

@gkatsev
Copy link
Member

gkatsev commented Aug 4, 2016

LGTM

@gkatsev gkatsev added the needs: LGTM Needs an additional approval label Aug 4, 2016
@misteroneill
Copy link
Member

LGTM

@misteroneill misteroneill added confirmed and removed needs: LGTM Needs an additional approval labels Aug 4, 2016
@misteroneill misteroneill merged commit d71d8d1 into videojs:vjsstandard-core Aug 4, 2016
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.

None yet

4 participants