forked from velesin/jasmine-jquery
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge commit 'b94ad8741909b8a48521d168a1ae6b742180122e'
* commit 'b94ad8741909b8a48521d168a1ae6b742180122e': (77 commits) 2.0.3 fix velesin#179 fix style fix toEqual() examples (velesin#176) Providing the parameters from jqXHR.fail 2.0.2 Update fixture to ignore script tag without src attribute Documentation fix 2.0.1 Run tests with jquery 2 Update ajax call to work with jquery 2 Update dependencies for jasmine v2 (close velesin#166) Fix matchers to be in alphabetical order and add toBeInDOM Update README docs for v2 (velesin#154) v2.0.0 - adds support for jasmine v2 (fix velesin#154, fix velesin#164) Update grunt-contrib-jasmine Run tests off of jasmine v2.0.0-rc3 Able to bind events to fixtures Pass in window to the self invoking function 1.7.0 ...
- Loading branch information
Showing
22 changed files
with
9,851 additions
and
13,578 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,18 @@ | ||
lib/external | ||
.idea | ||
lib-cov | ||
.grunt | ||
*.seed | ||
*.log | ||
*.csv | ||
*.dat | ||
*.out | ||
*.pid | ||
*.gz | ||
|
||
pids | ||
logs | ||
results | ||
|
||
npm-debug.log | ||
node_modules |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
var assert = require('assert'); | ||
|
||
module.exports = { | ||
|
||
'pull-requests': { | ||
'should always be made from feature branches': function (pull) { | ||
assert.notEqual(pull.head.ref, 'master') | ||
}, | ||
|
||
'should always include a unit test if changing js files': function (pull) { | ||
var hasJS = false | ||
var hasTests = false | ||
|
||
pull.files.forEach(function (file) { | ||
if (/^lib\/[^./]+.js/.test(file.filename)) hasJS = true | ||
if (/^spec\/suites\/[^.]+.js/.test(file.filename)) hasTests = true | ||
}) | ||
|
||
assert.ok(!hasJS || hasJS && hasTests) | ||
}, | ||
|
||
'after': function (pull) { | ||
if (pull.reporter.stats.failures) { | ||
pull.reportFailures(pull.close.bind(pull)) | ||
} | ||
} | ||
|
||
}, | ||
|
||
'issues': { | ||
|
||
'before': function (issue) { | ||
var plus = {} | ||
|
||
issue.comments.forEach(function (comment) { | ||
if (/\+1/.test(comment.body)) plus[comment.user.login] = true | ||
}) | ||
|
||
if (Object.keys(plus) > 10) issue.tag('popular') | ||
}, | ||
|
||
'should include a jsfiddle/jsbin illustrating the problem if tagged with js but not a feature': function (issue) { | ||
var labels = issue.labels.map(function (label) { return label.name }); | ||
if (~labels.indexOf('js') && !~labels.indexOf('feature')) assert.ok(/(jsfiddle|jsbin)/.test(issue.body)) | ||
}, | ||
|
||
'after': function (issue) { | ||
if (issue.reporter.stats.failures) { | ||
issue.reportFailures(issue.close.bind(issue)) | ||
} | ||
} | ||
|
||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
{ | ||
"validthis" : true | ||
, "multistr" : true | ||
, "laxcomma" : true | ||
, "laxbreak" : true | ||
, "browser" : true | ||
, "eqeqeq" : false | ||
, "eqnull" : true | ||
, "debug" : true | ||
, "devel" : true | ||
, "curly" : false | ||
, "boss" : true | ||
, "expr" : true | ||
, "asi" : true | ||
, "supernew" : true | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
language: node_js | ||
node_js: | ||
- 0.8 | ||
before_script: | ||
- npm install -g grunt-cli |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# Contributing to Jasmine-jQuery | ||
|
||
Looking to contribute something to Jasmine-jQuery? **Here's how you can help.** | ||
|
||
## Reporting issues | ||
|
||
We only accept issues that are bug reports or feature requests. Bugs must be isolated and reproducible problems that we can fix within the Jasmine-jQuery. Please read the following guidelines before opening any issue. | ||
|
||
1. **Search for existing issues.** Somemeone else may have reported the same issue. Moreover, the issue may have already been resolved with a fix available. | ||
2. **Create an isolated and reproducible test case.** Be sure the problem exists in Jasmine-jQuery's code with a [reduced test case](http://css-tricks.com/reduced-test-cases/) that should be included in each bug report. | ||
3. **Include a live example.** Make use of jsFiddle or jsBin to share your isolated test cases. | ||
4. **Share as much information as possible.** Include operating system and version, browser and version, version of Jasmine-jQuery. Also include steps to reproduce the bug. | ||
|
||
## Pull requests | ||
|
||
- Try not to pollute your pull request with unintended changes--keep them simple and small | ||
- Please squash your commits when appropriate. This simplifies future cherry picks, and also keeps the git log clean. | ||
- Include tests that fail without your code, and pass with it. | ||
- Update the documentation, examples elsewhere, and the guides: whatever is affected by your contribution. | ||
- If you can, have another developer sanity check your change. | ||
|
||
## Coding standards | ||
|
||
- No semicolons | ||
- Comma first | ||
- 2 spaces (no tabs) | ||
- strict mode | ||
- "Attractive" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
/* jshint node: true */ | ||
|
||
module.exports = function (grunt) { | ||
"use strict"; | ||
|
||
grunt.initConfig({ | ||
pkg: grunt.file.readJSON('package.json') | ||
, jshint: { | ||
all: [ | ||
"Gruntfile.js" | ||
, "lib/**/*.js" | ||
, "spec/**/*.js" | ||
] | ||
, options: { | ||
jshintrc: '.jshintrc' | ||
}, | ||
} | ||
, jasmine: { | ||
src: "lib/**/*.js" | ||
, options: { | ||
specs: "spec/**/*.js" | ||
, vendor: "vendor/**/*.js" | ||
, version: '2.0.0' | ||
} | ||
} | ||
}) | ||
|
||
grunt.loadNpmTasks('grunt-contrib-jshint') | ||
grunt.loadNpmTasks('grunt-contrib-jasmine') | ||
|
||
grunt.registerTask('test', ['jshint', 'jasmine']) | ||
grunt.registerTask('default', ['test']) | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.