Skip to content

Commit

Permalink
Added tests and support function
Browse files Browse the repository at this point in the history
  • Loading branch information
krisbulman committed Feb 10, 2015
1 parent ca7d79e commit 6bddd40
Show file tree
Hide file tree
Showing 25 changed files with 2,527 additions and 35 deletions.
36 changes: 36 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# Created by https://www.gitignore.io

### Node ###
# Logs
logs
*.log
.idea

# Runtime data
pids
*.pid
*.seed

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage

# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# node-waf configuration
.lock-wscript

# Compiled binary addons (http://nodejs.org/api/addons.html)
build/Release

# Dependency directory
# https://www.npmjs.org/doc/misc/npm-faq.html#should-i-check-my-node_modules-folder-into-git-
node_modules

### Sass ###
.sass-cache
*.css.map
Gemfile.lock
168 changes: 168 additions & 0 deletions .scss-lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,168 @@
# From http://sass-guidelin.es/#scss-lint

linters:

BangFormat:
enabled: true
space_before_bang: true
space_after_bang: false

BorderZero:
enabled: true

ColorKeyword:
enabled: false

Comment:
enabled: false

DebugStatement:
enabled: true

DeclarationOrder:
enabled: true

DuplicateProperty:
enabled: false

ElsePlacement:
enabled: true
style: same_line

EmptyLineBetweenBlocks:
enabled: true
ignore_single_line_blocks: false

EmptyRule:
enabled: true

FinalNewline:
enabled: true
present: true

HexLength:
enabled: true
style: short

HexNotation:
enabled: true
style: lowercase

HexValidation:
enabled: true

IdSelector:
enabled: true

ImportPath:
enabled: true
leading_underscore: false
filename_extension: false

Indentation:
enabled: true
character: space
width: 2

LeadingZero:
enabled: true
style: include_zero

MergeableSelector:
enabled: false
force_nesting: false

NameFormat:
enabled: true
convention: hyphenated_lowercase
allow_leading_underscore: true

NestingDepth:
enabled: true
max_depth: 3

PlaceholderInExtend:
enabled: true

PropertySortOrder:
enabled: false
ignore_unspecified: false

PropertySpelling:
enabled: true
extra_properties: []

QualifyingElement:
enabled: true
allow_element_with_attribute: false
allow_element_with_class: false
allow_element_with_id: false

SelectorDepth:
enabled: true
max_depth: 3

SelectorFormat:
enabled: true
convention: hyphenated_lowercase
class_convention: '^(?:u|is|has)\-[a-z][a-zA-Z0-9]*$|^(?!u|is|has)[a-zA-Z][a-zA-Z0-9]*(?:\-[a-z][a-zA-Z0-9]*)?(?:\-\-[a-z][a-zA-Z0-9]*)?$'

Shorthand:
enabled: true

SingleLinePerProperty:
enabled: true
allow_single_line_rule_sets: false

SingleLinePerSelector:
enabled: true

SpaceAfterComma:
enabled: true

SpaceAfterPropertyColon:
enabled: true
style: one_space

SpaceAfterPropertyName:
enabled: true

SpaceBeforeBrace:
enabled: true
style: space
allow_single_line_padding: true

SpaceBetweenParens:
enabled: true
spaces: 0

StringQuotes:
enabled: true
style: single_quotes

TrailingSemicolon:
enabled: true

TrailingZero:
enabled: true

UnnecessaryMantissa:
enabled: true

UnnecessaryParentReference:
enabled: true

UrlFormat:
enabled: false

UrlQuotes:
enabled: true

VendorPrefixes:
enabled: true
identifier_list: base
include: []
exclude: []

ZeroUnit:
enabled: true
12 changes: 12 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
language: node_js
node_js:
- "0.10"
before_install:
- 'npm install -g grunt-cli'
install:
- 'npm install'
before_script:
- 'gem update --system'
- 'gem install bundler'
- 'bundle install'
- 'grunt'
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
=== normalize-libsass 3.0.2-alpha.3+normalize.3.0.2 (February 9, 2015)
* Added tests
* Added browser support function to check against

=== normalize-libsass 3.0.2-alpha.2+normalize.3.0.2 (February 9, 2015)
* Fixed critical bug printing units with libsass
* Added additional browser support conditionals for ie
Expand Down
3 changes: 3 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
source "https://rubygems.org"

gem "scss-lint", "~> 0.33.0"
42 changes: 42 additions & 0 deletions Gruntfile.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
module.exports = function(grunt) {

grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
sass: {
options: {
},
dist: {
files: {
'tests/controls/font.css': 'tests/tests/font.scss',
'tests/controls/ie8.css': 'tests/tests/ie8.scss',
'tests/controls/ie9.css': 'tests/tests/ie9.scss',
'tests/controls/ie10.css': 'tests/tests/ie10.scss',
'tests/controls/ie11.css': 'tests/tests/ie11.scss',
'tests/controls/safari6.css': 'tests/tests/safari6.scss',
'tests/controls/safari7.css': 'tests/tests/safari7.scss'
}
}
},
clean: {
css: ['tests/controls/*.css']
},
scsslint: {
allFiles: [
'tests/tests/*.scss'
],
options: {
bundleExec: true,
config: '.scss-lint.yml',
reporterOutput: 'scss-lint-report.xml',
colorizeOutput: true
}
}
});

grunt.loadNpmTasks('grunt-sass');
grunt.loadNpmTasks('grunt-scss-lint');
grunt.loadNpmTasks('grunt-contrib-clean');

grunt.registerTask('default', ['clean:css', 'sass']);
grunt.registerTask('test', ['default', 'lint']);
};
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ normalizing.
## Install

* Download directly from the [project page](https://github.com/krisbulman/normalize-libsass/releases).
* Install with [Bower](http://bower.io/): bower install --save git://github.com/krisbulman/normalize-libsass.git#3.0.2-alpha.2+normalize.3.0.2
* Install with [Bower](http://bower.io/): bower install --save git://github.com/krisbulman/normalize-libsass.git#3.0.3-alpha.2+normalize.3.0.2
* Install with [Component](http://component.io/): component install krisbulman/normalize-libsass

No other styles should come before _normalize.scss.
Expand Down
Loading

0 comments on commit 6bddd40

Please sign in to comment.