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

Remove semicolons from JS tests #12058

Merged
merged 1 commit into from
Feb 18, 2014
Merged

Remove semicolons from JS tests #12058

merged 1 commit into from
Feb 18, 2014

Conversation

zlatanvasovic
Copy link
Contributor

💛

@ghost
Copy link

ghost commented Feb 1, 2014

This is fixed.

@zlatanvasovic
Copy link
Contributor Author

@twbs Can anybody review this as soon as possible? Every single change in JS unit test files may require start from scratch, so I need to do all the things again. 😟

@mdo
Copy link
Member

mdo commented Feb 8, 2014

Given the larger chunks of JS being rewritten, we need @fat to look into this.

@XhmikosR
Copy link
Member

Even after setting indent: 2 in jshintrc and fixing indentation for tests/*.js I keep getting warnings for the test files...

@zlatanvasovic
Copy link
Contributor Author

Hm?

@XhmikosR
Copy link
Member

NVM, I fixed the issues myself.

@XhmikosR
Copy link
Member

@zdroid: do you mind if I make a new PR for this and then you just rebase for the semicolons?

@zlatanvasovic
Copy link
Contributor Author

Hm. What was the problem with tests?

2014-02-13 9:09 GMT+01:00 XhmikosR [email protected]:

@zdroid https://github.com/ZDroid: do you mind if I make a new PR for
this and then you just rebase for the semicolons?


Reply to this email directly or view it on GitHubhttps://github.com//pull/12058#issuecomment-34956189
.

Zlatan Vasović - ZDroid

@XhmikosR
Copy link
Member

Well, it simply is easier for me to review my changes. This is one patch with indentation changes + semicolons.

@XhmikosR XhmikosR mentioned this pull request Feb 13, 2014
@XhmikosR
Copy link
Member

See #12720. After that is in, you can rebase your branch and update the PR to get only the semicolon changes.

@zlatanvasovic
Copy link
Contributor Author

JSHint can be bad with indent checking, especially when there is a indent
option. We should use JSCS for that.

Can these pull requests be done vice versa? First this for general coding
style then your for the rest? Rebase for 1.2k lines of code rewrite aren't
so easy. :(

You can also get access to ZDroid/bootstrap and add commits directly here,
so nobody needs the rebase. :D

2014-02-13 9:21 GMT+01:00 XhmikosR [email protected]:

See #12720 #12720. After that is
in, you can rebase your branch and update the PR to get only the semicolon
changes.


Reply to this email directly or view it on GitHubhttps://github.com//pull/12058#issuecomment-34956864
.

Zlatan Vasović - ZDroid

@XhmikosR
Copy link
Member

This was much easier for me to do it myself than reviewing this; if you hadn't mixed the indentation changes with the others I wouldn't mind...

@XhmikosR
Copy link
Member

BTW, I'm all for not using JSHint's indent option but for now it does the job as you can see from my PR. We can switch to JSCS after that.

@zlatanvasovic
Copy link
Contributor Author

Hm. I fixed indent, removed semicolons and removed transition support
statements as they're turned of in index.html. Some of these may collide
with yours.

2014-02-13 9:42 GMT+01:00 XhmikosR [email protected]:

BTW, I'm all for not using JSHint's indent option but for now it does the
job as you can see from my PR. We can switch to JSCS after that.


Reply to this email directly or view it on GitHubhttps://github.com//pull/12058#issuecomment-34958129
.

Zlatan Vasović - ZDroid

@XhmikosR
Copy link
Member

I will have a closer look later today and rebase your patch on top of mine.

@zlatanvasovic
Copy link
Contributor Author

OK.

2014-02-13 9:50 GMT+01:00 XhmikosR [email protected]:

I will have a closer look later today and rebase your patch on top of mine.


Reply to this email directly or view it on GitHubhttps://github.com//pull/12058#issuecomment-34958686
.

Zlatan Vasović - ZDroid

@XhmikosR
Copy link
Member

@zdroid: I checked your changes and I'm not sure they all make sense, so I won't include them in my PR. I suggest you wait until the other PR is merged and then create separate patches for the changes you make. For example, the semicolons change is fine, but some others aren't,

Rebasing wasn't so hard but there will be conflicts ofc.

@XhmikosR
Copy link
Member

I also tried JSCS but its indentation check seems weird to me... So I'll definitely leave this for another time.

@zlatanvasovic
Copy link
Contributor Author

OK so far.

2014-02-13 17:41 GMT+01:00 XhmikosR [email protected]:

I also tried JSCS but its indentation check seems weird to me... So I'll
definitely leave this for another time.


Reply to this email directly or view it on GitHubhttps://github.com//pull/12058#issuecomment-34997441
.

Zlatan Vasović - ZDroid

@XhmikosR
Copy link
Member

I had a closer look and the remaining indentation changes break grunt jshint. Please, rebase and keep the patches separately so that they are easily reviewed.

@zlatanvasovic
Copy link
Contributor Author

better?

@XhmikosR
Copy link
Member

Almost there :P

I think the semicolons removal should be done separately from the transition change.

* Licensed under the MIT license.
*/

/*global QUnit:true, alert:true*/
Copy link
Member

Choose a reason for hiding this comment

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

This should also be separate.

@zlatanvasovic
Copy link
Contributor Author

Lol. So I should make 3 (or 4) pull requests. :D

Can I just make 2: for semicolons and for the rest?

@XhmikosR
Copy link
Member

I meant separate patches, not separate pull requests.

@hnrch02
Copy link
Collaborator

hnrch02 commented Feb 17, 2014

I meant separate patches, not separate pull requests.

Just to clarify, basically a single PR with separate commits?

@zlatanvasovic
Copy link
Contributor Author

I just don't like pull requests with more than one commit. One commit per
pull request, best for merge.

2014-02-17 11:16 GMT+01:00 Heinrich Fenkart [email protected]:

I meant separate patches, not separate pull requests.

Just to clarify, basically a single PR with separate commits?


Reply to this email directly or view it on GitHubhttps://github.com//pull/12058#issuecomment-35243812
.

Zlatan Vasović - ZDroid

@XhmikosR
Copy link
Member

Commits are free; mixing different changes in the same commit is just bad practice.

All these changes refer to the same files; tests. That is why I suggested separate patches in the same PR. But separate PRs are ok I guess, if you insist on keeping one patch per PR.

@zlatanvasovic
Copy link
Contributor Author

One commit per pull request is pretty clear if you describe what is changed (like I did in the pull request description).

@XhmikosR
Copy link
Member

No, it's not. It's too generic patch which can be split up in clear, separate patches.

@zlatanvasovic
Copy link
Contributor Author

@XhmikosR I broke the pull request into 3 smaller ones.

@XhmikosR
Copy link
Member

LGTM now.

@cvrebert
Copy link
Collaborator

*rages internally about the semicolon thing generally*
Okay.

@XhmikosR
Copy link
Member

Semicolons, comma first, spaces vs tabs... So many different opinions :P

@zlatanvasovic
Copy link
Contributor Author

Yay. As @fat wrote the most of Bootstrap JS and Bootstrap docs JS code, he can make opinions about js/ (including js/tests/) and docs/assets/js/.

@XhmikosR
Copy link
Member

@zdroid: your last comment is irrelevant. I simply pointed out that there are so many different opinions on the style that things get complex.

@zlatanvasovic
Copy link
Contributor Author

Yes, but I talked specifically about semicolons. :P

2014-02-18 9:19 GMT+01:00 XhmikosR [email protected]:

@zdroid https://github.com/ZDroid: your last comment is irrelevant. I
simply pointed out that there are so many different opinions on the style
that things get complex.


Reply to this email directly or view it on GitHubhttps://github.com//pull/12058#issuecomment-35361692
.

Zlatan Vasović - ZDroid

@cvrebert
Copy link
Collaborator

@XhmikosR So, gonna merge this?

@XhmikosR
Copy link
Member

I guess so since that's the current style already.

@cvrebert
Copy link
Collaborator

:shipit: !

XhmikosR added a commit that referenced this pull request Feb 18, 2014
Remove semicolons from JS tests
@XhmikosR XhmikosR merged commit 25d047d into twbs:master Feb 18, 2014
@zlatanvasovic zlatanvasovic deleted the uti branch February 18, 2014 11:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants