oulu-rails 0.5.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/MIT-LICENSE +22 -0
- data/README.md +23 -0
- data/lib/oulu-rails/version.rb +3 -0
- data/lib/oulu-rails.rb +27 -0
- data/vendor/assets/javascripts/oulu/dev/positions-p.js.coffee +34 -0
- data/vendor/assets/javascripts/oulu/dev/positions-pp.js.coffee +57 -0
- data/vendor/assets/javascripts/oulu/dev/positions.js.coffee +6 -0
- data/vendor/assets/javascripts/oulu/helpers/js-autosize.js.coffee +2 -0
- data/vendor/assets/javascripts/oulu/helpers/js-checkbox.js.coffee +6 -0
- data/vendor/assets/javascripts/oulu/helpers/js-click-animate.js.coffee +8 -0
- data/vendor/assets/javascripts/oulu/helpers/js-delay-hidden.js.coffee +4 -0
- data/vendor/assets/javascripts/oulu/helpers/js-focused.js.coffee +7 -0
- data/vendor/assets/javascripts/oulu/helpers/js-hack.js.coffee +8 -0
- data/vendor/assets/javascripts/oulu/helpers/js-hide-after.j.coffee +5 -0
- data/vendor/assets/javascripts/oulu/helpers/js-hover-z-index.js.coffee +5 -0
- data/vendor/assets/javascripts/oulu/helpers/js-hovered.js.coffee +17 -0
- data/vendor/assets/javascripts/oulu/helpers/js-one-animate.js.coffee +5 -0
- data/vendor/assets/javascripts/oulu/helpers/js-open-children.js.coffee +28 -0
- data/vendor/assets/javascripts/oulu/helpers/js-open.js.coffee +51 -0
- data/vendor/assets/javascripts/oulu/helpers/js-scroll-to-top.js.coffee +11 -0
- data/vendor/assets/javascripts/oulu/helpers/js-scroll.js.coffee +9 -0
- data/vendor/assets/javascripts/oulu/helpers/js-side-slide.js.coffee +6 -0
- data/vendor/assets/javascripts/oulu/helpers/js-window-loading.js.coffee +15 -0
- data/vendor/assets/javascripts/oulu/helpers/js-window-sizes.js.coffee +6 -0
- data/vendor/assets/javascripts/oulu/helpers/open-close.js.coffee +23 -0
- data/vendor/assets/javascripts/oulu/ie/PIE_IE678.js +72 -0
- data/vendor/assets/javascripts/oulu/ie/PIE_IE9.js +46 -0
- data/vendor/assets/javascripts/oulu/ie/ie-selectors.js.coffee +3 -0
- data/vendor/assets/javascripts/oulu/ie/ie8-selectors.js.coffee +3 -0
- data/vendor/assets/javascripts/oulu/ie/ie9-selectors.js.coffee +6 -0
- data/vendor/assets/javascripts/oulu/ie/jquery.belatedPNG.min.js +29 -0
- data/vendor/assets/javascripts/oulu/ie/jquery.linkscubber.js +7 -0
- data/vendor/assets/javascripts/oulu/ie/svgeezy.min.js +12 -0
- data/vendor/assets/javascripts/oulu/plugins/check-box.js.coffee +34 -0
- data/vendor/assets/javascripts/oulu/plugins/footerFixed.js +74 -0
- data/vendor/assets/javascripts/oulu/plugins/jquery.autosize.min.js +7 -0
- data/vendor/assets/javascripts/oulu/plugins/jquery.cheat-code.js +63 -0
- data/vendor/assets/javascripts/oulu/plugins/jquery.css3form.js +195 -0
- data/vendor/assets/javascripts/oulu/plugins/jquery.depend.min.js +13 -0
- data/vendor/assets/javascripts/oulu/plugins/sns-buttons.js +339 -0
- data/vendor/assets/javascripts/oulu-ie8.js +6 -0
- data/vendor/assets/javascripts/oulu-ie9.js +2 -0
- data/vendor/assets/javascripts/oulu.js +2 -0
- data/vendor/assets/stylesheets/_oulu-base.css.sass +86 -0
- data/vendor/assets/stylesheets/_oulu.css.sass +13 -0
- data/vendor/assets/stylesheets/bootcamp/CHANGELOG.md +70 -0
- data/vendor/assets/stylesheets/bootcamp/CONTRIBUTING.md +72 -0
- data/vendor/assets/stylesheets/bootcamp/Gruntfile.coffee +34 -0
- data/vendor/assets/stylesheets/bootcamp/LICENSE.md +7 -0
- data/vendor/assets/stylesheets/bootcamp/README.md +52 -0
- data/vendor/assets/stylesheets/bootcamp/bower.json +15 -0
- data/vendor/assets/stylesheets/bootcamp/dist/_bootcamp.scss +46 -0
- data/vendor/assets/stylesheets/bootcamp/dist/bootcamp.coffee +101 -0
- data/vendor/assets/stylesheets/bootcamp/dist/core/functions/_actual.scss +3 -0
- data/vendor/assets/stylesheets/bootcamp/dist/core/functions/_error.scss +29 -0
- data/vendor/assets/stylesheets/bootcamp/dist/core/functions/_expect.scss +6 -0
- data/vendor/assets/stylesheets/bootcamp/dist/core/functions/_not-to.scss +5 -0
- data/vendor/assets/stylesheets/bootcamp/dist/core/functions/_should.scss +6 -0
- data/vendor/assets/stylesheets/bootcamp/dist/core/functions/_to.scss +5 -0
- data/vendor/assets/stylesheets/bootcamp/dist/core/mixins/_describe.scss +31 -0
- data/vendor/assets/stylesheets/bootcamp/dist/core/mixins/_it.scss +31 -0
- data/vendor/assets/stylesheets/bootcamp/dist/core/mixins/_runner.scss +28 -0
- data/vendor/assets/stylesheets/bootcamp/dist/core/mixins/_should.scss +46 -0
- data/vendor/assets/stylesheets/bootcamp/dist/core/mixins/_xdescribe.scss +9 -0
- data/vendor/assets/stylesheets/bootcamp/dist/core/mixins/_xit.scss +9 -0
- data/vendor/assets/stylesheets/bootcamp/dist/core/variables/_helpers.scss +5 -0
- data/vendor/assets/stylesheets/bootcamp/dist/core/variables/_settings.scss +2 -0
- data/vendor/assets/stylesheets/bootcamp/dist/core/variables/_should.scss +6 -0
- data/vendor/assets/stylesheets/bootcamp/dist/core/variables/_trackers.scss +6 -0
- data/vendor/assets/stylesheets/bootcamp/dist/lib/_sassyjson.scss +1075 -0
- data/vendor/assets/stylesheets/bootcamp/dist/matchers/_be.scss +3 -0
- data/vendor/assets/stylesheets/bootcamp/dist/matchers/_equal.scss +3 -0
- data/vendor/assets/stylesheets/bootcamp/dist/matchers/lists/_be-empty.scss +3 -0
- data/vendor/assets/stylesheets/bootcamp/dist/matchers/lists/_be-longer-than.scss +3 -0
- data/vendor/assets/stylesheets/bootcamp/dist/matchers/lists/_be-shorter-than.scss +3 -0
- data/vendor/assets/stylesheets/bootcamp/dist/matchers/lists/_contain.scss +3 -0
- data/vendor/assets/stylesheets/bootcamp/dist/matchers/lists/_deep-contain.scss +3 -0
- data/vendor/assets/stylesheets/bootcamp/dist/matchers/lists/_deep-equal.scss +47 -0
- data/vendor/assets/stylesheets/bootcamp/dist/matchers/lists/_have-length-of.scss +3 -0
- data/vendor/assets/stylesheets/bootcamp/dist/matchers/numbers/_be-close-to.scss +12 -0
- data/vendor/assets/stylesheets/bootcamp/dist/matchers/numbers/_be-greater-than.scss +12 -0
- data/vendor/assets/stylesheets/bootcamp/dist/matchers/numbers/_be-less-than.scss +12 -0
- data/vendor/assets/stylesheets/bootcamp/dist/matchers/types/_be-falsy.scss +3 -0
- data/vendor/assets/stylesheets/bootcamp/dist/matchers/types/_be-null.scss +3 -0
- data/vendor/assets/stylesheets/bootcamp/dist/matchers/types/_be-truthy.scss +3 -0
- data/vendor/assets/stylesheets/bootcamp/dist/matchers/types/_have-type-of.scss +3 -0
- data/vendor/assets/stylesheets/bootcamp/dist/utils/_contain.scss +15 -0
- data/vendor/assets/stylesheets/bootcamp/dist/utils/_equal.scss +23 -0
- data/vendor/assets/stylesheets/bootcamp/dist/utils/_list-join.scss +35 -0
- data/vendor/assets/stylesheets/bootcamp/dist/utils/_power.scss +15 -0
- data/vendor/assets/stylesheets/bootcamp/package.json +63 -0
- data/vendor/assets/stylesheets/bootcamp/tasks/bootcamp.coffee +83 -0
- data/vendor/assets/stylesheets/bootcamp/test/core/functions/_actual.scss +10 -0
- data/vendor/assets/stylesheets/bootcamp/test/core/functions/_expect.scss +6 -0
- data/vendor/assets/stylesheets/bootcamp/test/core/functions/_not-to.scss +5 -0
- data/vendor/assets/stylesheets/bootcamp/test/core/functions/_should.scss +10 -0
- data/vendor/assets/stylesheets/bootcamp/test/core/functions/_to.scss +5 -0
- data/vendor/assets/stylesheets/bootcamp/test/core/mixins/_describe.scss +11 -0
- data/vendor/assets/stylesheets/bootcamp/test/core/mixins/_it.scss +5 -0
- data/vendor/assets/stylesheets/bootcamp/test/core/mixins/_should.scss +5 -0
- data/vendor/assets/stylesheets/bootcamp/test/core/mixins/_xdescribe.scss +28 -0
- data/vendor/assets/stylesheets/bootcamp/test/core/mixins/_xit.scss +12 -0
- data/vendor/assets/stylesheets/bootcamp/test/matchers/_be.scss +90 -0
- data/vendor/assets/stylesheets/bootcamp/test/matchers/_equal.scss +33 -0
- data/vendor/assets/stylesheets/bootcamp/test/matchers/lists/_be-empty.scss +12 -0
- data/vendor/assets/stylesheets/bootcamp/test/matchers/lists/_be-longer-than.scss +29 -0
- data/vendor/assets/stylesheets/bootcamp/test/matchers/lists/_be-shorter-than.scss +29 -0
- data/vendor/assets/stylesheets/bootcamp/test/matchers/lists/_contain.scss +39 -0
- data/vendor/assets/stylesheets/bootcamp/test/matchers/lists/_deep-contain.scss +51 -0
- data/vendor/assets/stylesheets/bootcamp/test/matchers/lists/_deep-equal.scss +151 -0
- data/vendor/assets/stylesheets/bootcamp/test/matchers/lists/_have-length-of.scss +31 -0
- data/vendor/assets/stylesheets/bootcamp/test/matchers/numbers/_be-close-to.scss +24 -0
- data/vendor/assets/stylesheets/bootcamp/test/matchers/numbers/_be-greater-than.scss +16 -0
- data/vendor/assets/stylesheets/bootcamp/test/matchers/numbers/_be-less-than.scss +16 -0
- data/vendor/assets/stylesheets/bootcamp/test/matchers/types/_be-falsy.scss +14 -0
- data/vendor/assets/stylesheets/bootcamp/test/matchers/types/_be-null.scss +13 -0
- data/vendor/assets/stylesheets/bootcamp/test/matchers/types/_be-truthy.scss +13 -0
- data/vendor/assets/stylesheets/bootcamp/test/matchers/types/_have-type-of.scss +17 -0
- data/vendor/assets/stylesheets/bootcamp/test/specs.scss +45 -0
- data/vendor/assets/stylesheets/bootcamp/test/utils/_contain.scss +41 -0
- data/vendor/assets/stylesheets/bootcamp/test/utils/_equal.scss +79 -0
- data/vendor/assets/stylesheets/bootcamp/test/utils/_list-join.scss +39 -0
- data/vendor/assets/stylesheets/bootcamp/test/utils/_power.scss +13 -0
- data/vendor/assets/stylesheets/helper/_base-helper.css.sass +133 -0
- data/vendor/assets/stylesheets/helper/_click-actions.css.sass +188 -0
- data/vendor/assets/stylesheets/helper/_fade-actions.css.sass +30 -0
- data/vendor/assets/stylesheets/helper/_margin-padding.css.sass +16 -0
- data/vendor/assets/stylesheets/helper/_typoglaphy.css.sass +9 -0
- data/vendor/assets/stylesheets/options/amazlet/_amazlet.css.sass +32 -0
- data/vendor/assets/stylesheets/options/glitch/_glitch.css.sass +31 -0
- data/vendor/assets/stylesheets/options/oulu-buttons/_button-basic.css.sass +31 -0
- data/vendor/assets/stylesheets/options/web-fonts/_cousine.css.sass +12 -0
- data/vendor/assets/stylesheets/options/web-fonts/_font-awsome.css.sass +8 -0
- data/vendor/assets/stylesheets/options/web-fonts/_icomoon.css.sass +10 -0
- data/vendor/assets/stylesheets/options/web-fonts/_lato.css.sass +12 -0
- data/vendor/assets/stylesheets/options/web-fonts/_montserrat.css.sass +13 -0
- data/vendor/assets/stylesheets/options/web-fonts/_old-standard.css.sass +12 -0
- data/vendor/assets/stylesheets/options/web-fonts/_open-sans.css.sass +11 -0
- data/vendor/assets/stylesheets/options/web-fonts/_podkova.css.sass +12 -0
- data/vendor/assets/stylesheets/options/web-fonts/_pt-sans.css.sass +12 -0
- data/vendor/assets/stylesheets/options/web-fonts/_roboto.css.sass +11 -0
- data/vendor/assets/stylesheets/options/web-fonts/_satisfy.css.sass +13 -0
- data/vendor/assets/stylesheets/options/web-fonts/_source-code-pro.css.sass +13 -0
- data/vendor/assets/stylesheets/options/web-fonts/_source-sans-pro.css.sass +13 -0
- data/vendor/assets/stylesheets/options/web-fonts/_special-elite.css.sass +12 -0
- data/vendor/assets/stylesheets/options/web-fonts/_tauri.css.sass +11 -0
- data/vendor/assets/stylesheets/options/web-fonts/_ubuntu.css.sass +12 -0
- data/vendor/assets/stylesheets/settings/functions/_background.css.sass +60 -0
- data/vendor/assets/stylesheets/settings/functions/_bool.css.sass +5 -0
- data/vendor/assets/stylesheets/settings/functions/_border.css.sass +47 -0
- data/vendor/assets/stylesheets/settings/functions/_color.css.sass +65 -0
- data/vendor/assets/stylesheets/settings/functions/_content.css.sass +5 -0
- data/vendor/assets/stylesheets/settings/functions/_cursor.css.sass +5 -0
- data/vendor/assets/stylesheets/settings/functions/_direction.css.sass +8 -0
- data/vendor/assets/stylesheets/settings/functions/_image.css.sass +8 -0
- data/vendor/assets/stylesheets/settings/functions/_length.css.sass +20 -0
- data/vendor/assets/stylesheets/settings/functions/_list.css.sass +11 -0
- data/vendor/assets/stylesheets/settings/functions/_map.css.sass +5 -0
- data/vendor/assets/stylesheets/settings/functions/_number.css.sass +63 -0
- data/vendor/assets/stylesheets/settings/functions/_position.css.sass +47 -0
- data/vendor/assets/stylesheets/settings/functions/_reverse.css.sass +22 -0
- data/vendor/assets/stylesheets/settings/functions/_string.css.sass +5 -0
- data/vendor/assets/stylesheets/settings/functions/_text.css.sass +34 -0
- data/vendor/assets/stylesheets/settings/initializers/_reset.css.sass +85 -0
- data/vendor/assets/stylesheets/settings/mixins/_animation.css.sass +15 -0
- data/vendor/assets/stylesheets/settings/mixins/_background.css.sass +33 -0
- data/vendor/assets/stylesheets/settings/mixins/_balloon-tale.css.sass +111 -0
- data/vendor/assets/stylesheets/settings/mixins/_basic-font.css.sass +40 -0
- data/vendor/assets/stylesheets/settings/mixins/_block.css.sass +30 -0
- data/vendor/assets/stylesheets/settings/mixins/_border.css.sass +28 -0
- data/vendor/assets/stylesheets/settings/mixins/_button-base.css.sass +27 -0
- data/vendor/assets/stylesheets/settings/mixins/_clear-type.css.sass +4 -0
- data/vendor/assets/stylesheets/settings/mixins/_color.css.sass +9 -0
- data/vendor/assets/stylesheets/settings/mixins/_filters.css.sass +5 -0
- data/vendor/assets/stylesheets/settings/mixins/_form.css.sass +7 -0
- data/vendor/assets/stylesheets/settings/mixins/_grids.css.sass +149 -0
- data/vendor/assets/stylesheets/settings/mixins/_html5-input-types.scss +118 -0
- data/vendor/assets/stylesheets/settings/mixins/_ie-hacks.css.sass +8 -0
- data/vendor/assets/stylesheets/settings/mixins/_lines.css.sass +18 -0
- data/vendor/assets/stylesheets/settings/mixins/_link.css.sass +11 -0
- data/vendor/assets/stylesheets/settings/mixins/_list.css.sass +21 -0
- data/vendor/assets/stylesheets/settings/mixins/_margin-padding.css.sass +69 -0
- data/vendor/assets/stylesheets/settings/mixins/_overlay.css.sass +5 -0
- data/vendor/assets/stylesheets/settings/mixins/_positions.css.sass +28 -0
- data/vendor/assets/stylesheets/settings/mixins/_rem.css.sass +53 -0
- data/vendor/assets/stylesheets/settings/mixins/_resets.css.sass +17 -0
- data/vendor/assets/stylesheets/settings/mixins/_responsive-utilities.css.sass +160 -0
- data/vendor/assets/stylesheets/settings/mixins/_sassmatic.css.sass +172 -0
- data/vendor/assets/stylesheets/settings/mixins/_sprite-background.css.sass +18 -0
- data/vendor/assets/stylesheets/settings/mixins/_tables.css.sass +14 -0
- data/vendor/assets/stylesheets/settings/mixins/_text.css.sass +21 -0
- data/vendor/assets/stylesheets/settings/variables/_default.css.sass +69 -0
- metadata +362 -0
@@ -0,0 +1,52 @@
|
|
1
|
+
Bootcamp [![NPM version](https://badge.fury.io/js/bootcamp.png)](http://badge.fury.io/js/bootcamp) [![Build Status](https://travis-ci.org/thejameskyle/bootcamp.png?branch=master)](https://travis-ci.org/thejameskyle/bootcamp) [![Dependency Status](https://david-dm.org/thejameskyle/bootcamp.png)](https://david-dm.org/thejameskyle/bootcamp) [![devDependency Status](https://david-dm.org/thejameskyle/bootcamp/dev-status.png)](https://david-dm.org/thejameskyle/bootcamp#info=devDependencies)
|
2
|
+
========
|
3
|
+
|
4
|
+
Jasmine-style BDD testing written in Sass for Sass.
|
5
|
+
|
6
|
+
#### [Read Introduction >](https://github.com/thejameskyle/bootcamp/wiki/Introduction)
|
7
|
+
|
8
|
+
#### [Read Setup >](https://github.com/thejameskyle/bootcamp/wiki/Setup)
|
9
|
+
|
10
|
+
#### [See Example Test Suite >](https://github.com/thejameskyle/bootcamp/wiki/Example-Test-Suite)
|
11
|
+
|
12
|
+
#### [Authoring Matchers >](https://github.com/thejameskyle/bootcamp/wiki/Authoring-Matchers)
|
13
|
+
|
14
|
+
## Install
|
15
|
+
|
16
|
+
In the future, Bootcamp will hopefully be available in more ways, for now you can either clone the repo yourself, install via [bower](http://bower.io/), or install via [npm](https://npmjs.org/) as a grunt plugin. If you would like, please help create a [yeoman generator](http://yeoman.io/), a [ruby gem](http://rubygems.org/), or any other package manager you'd like out there.
|
17
|
+
|
18
|
+
#### Git
|
19
|
+
|
20
|
+
```
|
21
|
+
git clone git@github.com:thejameskyle/bootcamp.git && cd bootcamp
|
22
|
+
```
|
23
|
+
|
24
|
+
#### Bower
|
25
|
+
|
26
|
+
```
|
27
|
+
bower install bootcamp --save-dev
|
28
|
+
```
|
29
|
+
|
30
|
+
#### npm
|
31
|
+
|
32
|
+
```
|
33
|
+
npm install bootcamp --save-dev
|
34
|
+
```
|
35
|
+
|
36
|
+
## Support
|
37
|
+
|
38
|
+
Have a question or need help? Tweet [@thejameskyle](https://twitter.com/thejameskyle).
|
39
|
+
|
40
|
+
## Contributing
|
41
|
+
|
42
|
+
As an open-source project, contributions are more than welcome, they're extremely helpful and actively encouraged. If you see any room for improvement, open an [issue](https://github.com/thejameskyle/bootcamp/issues) or submit a [pull request](https://github.com/thejameskyle/bootcamp/pulls). Also make sure to take a look at the [contributing doc](CONTRIBUTING.md).
|
43
|
+
|
44
|
+
## License
|
45
|
+
|
46
|
+
This project is provided under the terms of the [MIT License](LICENSE.md).
|
47
|
+
|
48
|
+
---
|
49
|
+
|
50
|
+
Authored by **James Kyle** · [Github](https://github.com/thejameskyle) · [Twitter](https://twitter.com/thejameskyle) · [CodePen](https://codepen.com/thejameskyle)
|
51
|
+
|
52
|
+
[Built Equal >](http://www.hrc.org/donate) · [Made in Boston >](http://bostonbuilt.org/)
|
@@ -0,0 +1,15 @@
|
|
1
|
+
{
|
2
|
+
"name": "bootcamp",
|
3
|
+
"version": "1.1.7",
|
4
|
+
"homepage": "http://github.com/thejameskyle/bootcamp",
|
5
|
+
"main": "dist/bootcamp.scss",
|
6
|
+
"ignore": [
|
7
|
+
"test",
|
8
|
+
".editorconfig",
|
9
|
+
".gitattributes",
|
10
|
+
".gitignore",
|
11
|
+
".jshintrc",
|
12
|
+
".travis.yml",
|
13
|
+
"Gruntfile.coffee"
|
14
|
+
]
|
15
|
+
}
|
@@ -0,0 +1,46 @@
|
|
1
|
+
@import "lib/sassyjson";
|
2
|
+
|
3
|
+
@import "core/variables/settings";
|
4
|
+
|
5
|
+
@import "core/variables/helpers";
|
6
|
+
@import "core/variables/should";
|
7
|
+
@import "core/variables/trackers";
|
8
|
+
|
9
|
+
@import "core/mixins/describe";
|
10
|
+
@import "core/mixins/it";
|
11
|
+
@import "core/mixins/runner";
|
12
|
+
@import "core/mixins/should";
|
13
|
+
@import "core/mixins/xdescribe";
|
14
|
+
@import "core/mixins/xit";
|
15
|
+
|
16
|
+
@import "core/functions/actual";
|
17
|
+
@import "core/functions/error";
|
18
|
+
@import "core/functions/expect";
|
19
|
+
@import "core/functions/not-to";
|
20
|
+
@import "core/functions/should";
|
21
|
+
@import "core/functions/to";
|
22
|
+
|
23
|
+
@import "utils/contain";
|
24
|
+
@import "utils/equal";
|
25
|
+
@import "utils/list-join";
|
26
|
+
@import "utils/power";
|
27
|
+
|
28
|
+
@import "matchers/be";
|
29
|
+
@import "matchers/equal";
|
30
|
+
|
31
|
+
@import "matchers/lists/be-empty";
|
32
|
+
@import "matchers/lists/be-longer-than";
|
33
|
+
@import "matchers/lists/be-shorter-than";
|
34
|
+
@import "matchers/lists/contain";
|
35
|
+
@import "matchers/lists/deep-contain";
|
36
|
+
@import "matchers/lists/deep-equal";
|
37
|
+
@import "matchers/lists/have-length-of";
|
38
|
+
|
39
|
+
@import "matchers/numbers/be-close-to";
|
40
|
+
@import "matchers/numbers/be-greater-than";
|
41
|
+
@import "matchers/numbers/be-less-than";
|
42
|
+
|
43
|
+
@import "matchers/types/be-falsy";
|
44
|
+
@import "matchers/types/be-null";
|
45
|
+
@import "matchers/types/be-truthy";
|
46
|
+
@import "matchers/types/have-type-of";
|
@@ -0,0 +1,101 @@
|
|
1
|
+
'use strict'
|
2
|
+
|
3
|
+
fs = require 'fs'
|
4
|
+
|
5
|
+
module.exports =
|
6
|
+
test: (filepath) ->
|
7
|
+
error = null
|
8
|
+
|
9
|
+
file = fs.readFileSync filepath, 'utf8'
|
10
|
+
|
11
|
+
###
|
12
|
+
# Get Camp
|
13
|
+
###
|
14
|
+
|
15
|
+
camp = file.match /\/\* >> Bootcamp >> \*\/((.|\n|\r)*)\/\* << Bootcamp << \*\//
|
16
|
+
|
17
|
+
unless camp?
|
18
|
+
return incomplete: true, error: 'No Test Suite Found'
|
19
|
+
else
|
20
|
+
camp = camp[1]
|
21
|
+
|
22
|
+
###
|
23
|
+
# Get Results
|
24
|
+
###
|
25
|
+
|
26
|
+
results = camp.match /Test Results \{((.|\n|\r)*)\}/
|
27
|
+
|
28
|
+
unless results?
|
29
|
+
return incomplete: true, error: 'No Test Results Found'
|
30
|
+
else
|
31
|
+
results = results[1]
|
32
|
+
|
33
|
+
###
|
34
|
+
# Get Specs
|
35
|
+
###
|
36
|
+
|
37
|
+
specs = camp.replace( results, '' ).replace( /Test Results \{\}|\{|\}|;|:/g, '' )
|
38
|
+
|
39
|
+
###
|
40
|
+
# method: getProperty
|
41
|
+
###
|
42
|
+
|
43
|
+
getProperty = (property, force) ->
|
44
|
+
values = results.match new RegExp property + ': ((.|\n|\r)*?);', 'g'
|
45
|
+
property = []
|
46
|
+
|
47
|
+
if force and !values? then return property
|
48
|
+
|
49
|
+
unless values?
|
50
|
+
error = incomplete: true, error: "No #{property} Found"
|
51
|
+
return false
|
52
|
+
else
|
53
|
+
for value in values
|
54
|
+
value = value.replace(/;/, '')
|
55
|
+
value = value.replace(/(.*:)/, '')
|
56
|
+
value = value.trim()
|
57
|
+
value = parseInt value unless isNaN value
|
58
|
+
property.push value
|
59
|
+
|
60
|
+
return property
|
61
|
+
|
62
|
+
###
|
63
|
+
# Get Properties
|
64
|
+
###
|
65
|
+
|
66
|
+
success = getProperty('Success').indexOf('true') > -1
|
67
|
+
stats = getProperty 'Stats'
|
68
|
+
tests = getProperty 'Tests'
|
69
|
+
asserts = getProperty 'Asserts'
|
70
|
+
passed = getProperty 'Passed'
|
71
|
+
failed = getProperty 'Failed'
|
72
|
+
skipped = getProperty 'Skipped'
|
73
|
+
errors = getProperty 'Error', true
|
74
|
+
|
75
|
+
###
|
76
|
+
# Return Any Errors
|
77
|
+
###
|
78
|
+
|
79
|
+
return error if error
|
80
|
+
|
81
|
+
###
|
82
|
+
# Return Final Values
|
83
|
+
###
|
84
|
+
|
85
|
+
return {
|
86
|
+
camp: camp
|
87
|
+
results: results
|
88
|
+
specs: specs
|
89
|
+
|
90
|
+
success: success
|
91
|
+
stats: stats
|
92
|
+
details: "#{tests} Tests, #{asserts} assertions, #{failed} failures, #{skipped} skipped"
|
93
|
+
|
94
|
+
tests: tests
|
95
|
+
asserts: asserts
|
96
|
+
passed: passed
|
97
|
+
failed: failed
|
98
|
+
skipped: skipped
|
99
|
+
|
100
|
+
errors: errors
|
101
|
+
}
|
@@ -0,0 +1,29 @@
|
|
1
|
+
@function error($type, $message) {
|
2
|
+
$title: null;
|
3
|
+
|
4
|
+
@if $type == "type" {
|
5
|
+
$title: "TYPE ERROR";
|
6
|
+
}
|
7
|
+
|
8
|
+
@else if $type == "warn" {
|
9
|
+
$title: "WARNING"
|
10
|
+
}
|
11
|
+
|
12
|
+
@else if $type == "dep" {
|
13
|
+
$title: "DEPRECATED"
|
14
|
+
}
|
15
|
+
|
16
|
+
@else if $type == "fatal" {
|
17
|
+
$bc-error: true !global;
|
18
|
+
$title: "FATAL ERROR";
|
19
|
+
}
|
20
|
+
|
21
|
+
@else {
|
22
|
+
$bc-error: true !global;
|
23
|
+
$title: "ERROR";
|
24
|
+
}
|
25
|
+
|
26
|
+
$bc-error-text: "!#{$title}! #{$message}." !global;
|
27
|
+
|
28
|
+
@return false;
|
29
|
+
}
|
@@ -0,0 +1,31 @@
|
|
1
|
+
@mixin describe($bc-describe-new) {
|
2
|
+
@if not $bc-skipping {
|
3
|
+
$bc-describe-old: $bc-describe !global !default;
|
4
|
+
$bc-describe-old: append($bc-describe-old, $bc-describe-new) !global;
|
5
|
+
|
6
|
+
@if $bc-describe-depth > 0 {
|
7
|
+
$bc-describe: bc-util-list-join($bc-describe-old, " ", 2) !global;
|
8
|
+
} @else {
|
9
|
+
$bc-describe: "#{$bc-describe-new}" !global;
|
10
|
+
}
|
11
|
+
|
12
|
+
$bc-describe-depth: $bc-describe-depth + 1 !global;
|
13
|
+
|
14
|
+
@content;
|
15
|
+
|
16
|
+
$bc-describe: "" !global;
|
17
|
+
|
18
|
+
$_tmp: ();
|
19
|
+
|
20
|
+
@for $i from 1 through $bc-describe-depth {
|
21
|
+
$_tmp: append($_tmp, nth($bc-describe-old, $i));
|
22
|
+
}
|
23
|
+
|
24
|
+
$bc-describe-old: $_tmp !global;
|
25
|
+
$bc-describe: nth($bc-describe-old, 1) !global;
|
26
|
+
$bc-describe-depth: $bc-describe-depth - 1 !global;
|
27
|
+
|
28
|
+
} @else {
|
29
|
+
@content;
|
30
|
+
}
|
31
|
+
}
|
@@ -0,0 +1,31 @@
|
|
1
|
+
@mixin it($statement) {
|
2
|
+
$bc-total: $bc-total + 1 !global;
|
3
|
+
|
4
|
+
@if not $bc-skipping {
|
5
|
+
$bc-passing: true !global;
|
6
|
+
|
7
|
+
#{$bc-describe} #{$statement} {
|
8
|
+
@content;
|
9
|
+
|
10
|
+
@if $bc-passing {
|
11
|
+
@if $bc-setting-verbose {
|
12
|
+
Test: Passed;
|
13
|
+
}
|
14
|
+
|
15
|
+
$bc-stats: "#{$bc-stats} ✔" !global;
|
16
|
+
$bc-passed: $bc-passed + 1 !global;
|
17
|
+
}
|
18
|
+
|
19
|
+
@else {
|
20
|
+
Test: Failed;
|
21
|
+
|
22
|
+
$bc-stats: "#{$bc-stats} ✗" !global;
|
23
|
+
$bc-failed: $bc-failed + 1 !global;
|
24
|
+
}
|
25
|
+
}
|
26
|
+
|
27
|
+
$bc-passing: null !global;
|
28
|
+
} @else {
|
29
|
+
$bc-skipped: $bc-skipped + 1 !global;
|
30
|
+
}
|
31
|
+
}
|
@@ -0,0 +1,28 @@
|
|
1
|
+
@mixin runner-start {
|
2
|
+
/* >> Bootcamp >> */
|
3
|
+
}
|
4
|
+
|
5
|
+
@mixin runner-end {
|
6
|
+
|
7
|
+
@if $bc-total == 0 {
|
8
|
+
$bc-stats: "No tests were found" !global;
|
9
|
+
}
|
10
|
+
|
11
|
+
Test Results {
|
12
|
+
Success: $bc-failed == 0;
|
13
|
+
Stats: #{ $bc-stats };
|
14
|
+
Tests: #{ $bc-total };
|
15
|
+
Asserts: #{ $bc-asserts };
|
16
|
+
Passed: #{ $bc-passed };
|
17
|
+
Failed: #{ $bc-failed };
|
18
|
+
Skipped: #{ $bc-skipped };
|
19
|
+
|
20
|
+
@if $bc-errors != () and $bc-setting-warnings {
|
21
|
+
@each $error in $bc-errors {
|
22
|
+
Error: #{$error};
|
23
|
+
}
|
24
|
+
}
|
25
|
+
}
|
26
|
+
|
27
|
+
/* << Bootcamp << */
|
28
|
+
}
|
@@ -0,0 +1,46 @@
|
|
1
|
+
@mixin should($actual, $expect) {
|
2
|
+
@if $bc-error {
|
3
|
+
$expect: false !global;
|
4
|
+
}
|
5
|
+
|
6
|
+
$bc-asserts: $bc-asserts + 1 !global;
|
7
|
+
|
8
|
+
$bc-actual: json-encode($bc-actual) !global;
|
9
|
+
$bc-expect: json-encode($bc-expect) !global;
|
10
|
+
|
11
|
+
@if not $expect {
|
12
|
+
$bc-passing: false !global;
|
13
|
+
}
|
14
|
+
|
15
|
+
@if not $expect or $bc-setting-verbose {
|
16
|
+
$status: " ✗";
|
17
|
+
|
18
|
+
@if $bc-passing {
|
19
|
+
$status: " ✔";
|
20
|
+
}
|
21
|
+
|
22
|
+
@if $bc-error-text {
|
23
|
+
#{$status}:
|
24
|
+
#{$bc-error-text}
|
25
|
+
#{$bc-actual-text} #{$bc-actual}
|
26
|
+
#{$bc-expect-text} #{$bc-expect};
|
27
|
+
} @else {
|
28
|
+
#{$status}:
|
29
|
+
#{$bc-actual-text} #{$bc-actual}
|
30
|
+
#{$bc-expect-text} #{$bc-expect};
|
31
|
+
}
|
32
|
+
}
|
33
|
+
|
34
|
+
@if $bc-error-text {
|
35
|
+
@if not index($bc-errors, $bc-error-text) {
|
36
|
+
$bc-errors: append($bc-errors, $bc-error-text) !global;
|
37
|
+
}
|
38
|
+
}
|
39
|
+
|
40
|
+
$bc-actual-text: null !global;
|
41
|
+
$bc-expect-text: null !global;
|
42
|
+
$bc-actual: null !global;
|
43
|
+
$bc-expect: null !global;
|
44
|
+
$bc-error-text: null !global;
|
45
|
+
$bc-error: false !global;
|
46
|
+
}
|