sassc 1.6.0 → 1.7.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: bac3ffe63156b284a72c2c8496c06a5b14bccc62
4
- data.tar.gz: 55a875b297d4253f639461174e5ddd33dbe464e6
3
+ metadata.gz: 62e4ec4266611c62b060eae6937787bead1d15d8
4
+ data.tar.gz: 7358166ce24865e5bcc91196ff0ada17d50e8081
5
5
  SHA512:
6
- metadata.gz: fe168c4733030c3fe7132a38c3ea09ebf03113e665cbb3df82abfdf114a32a361dc1673083037b8c9d1d6174b87e7f86e75ecdfacf23a4c3144fe1d2e7b3c499
7
- data.tar.gz: 3159f2ef6faf4f214b1a788104f1d14511fe3d4e50503e81843821e0a05959e339b1b98514b8e8d502e278003557c0bdacb31015909d6aa440f5a79d1725dbb4
6
+ metadata.gz: 67e857ad4f8323db3d440964ee19108983e789ace0acb80b6de18563b6a414d4539e95a05915ea3bee1678e45d94787c1ca6055ff977b9ab8d902bb26d4013ab
7
+ data.tar.gz: 2797cfbda1566dd45c1f6f73d82f327d3ed4803af309e59e183444bf57635b32e1d4b48d2b40eb2ab6efd7c9bfebe370883bf369bd160d0b6339198a29568bea
data/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # SassC [![Build Status](https://travis-ci.org/bolandrm/sassc-ruby.svg?branch=master)](https://travis-ci.org/bolandrm/sassc-ruby) [![Gem Version](https://badge.fury.io/rb/sassc.svg)](http://badge.fury.io/rb/sassc)
1
+ # SassC [![Build Status](https://travis-ci.org/sass/sassc-ruby.svg?branch=master)](https://travis-ci.org/sass/sassc-ruby) [![Gem Version](https://badge.fury.io/rb/sassc.svg)](http://badge.fury.io/rb/sassc)
2
2
 
3
3
  Use `libsass` with Ruby!
4
4
 
@@ -25,6 +25,8 @@ and [awesome contributors](https://github.com/bolandrm/sassc-ruby/graphs/contrib
25
25
 
26
26
  ## Changelog
27
27
 
28
+ - **1.7.0**
29
+ - [Support Precision](https://github.com/sass/sassc-ruby/pull/19)
28
30
  - **1.6.0**
29
31
  - [Support Sass Color types](https://github.com/bolandrm/sassc-ruby/pull/14)
30
32
  - [Support quoted strings](https://github.com/bolandrm/sassc-ruby/pull/13)
@@ -21,6 +21,7 @@ module SassC
21
21
 
22
22
  Native.option_set_is_indented_syntax_src(native_options, true) if sass?
23
23
  Native.option_set_input_path(native_options, filename) if filename
24
+ Native.option_set_precision(native_options, precision) if precision
24
25
  Native.option_set_include_path(native_options, load_paths)
25
26
  Native.option_set_output_style(native_options, output_style_enum)
26
27
  Native.option_set_source_comments(native_options, true) if line_comments?
@@ -64,6 +65,10 @@ module SassC
64
65
  @options[:filename]
65
66
  end
66
67
 
68
+ def precision
69
+ @options[:precision]
70
+ end
71
+
67
72
  def sass?
68
73
  @options[:syntax] && @options[:syntax].to_sym == :sass
69
74
  end
@@ -1,3 +1,3 @@
1
1
  module SassC
2
- VERSION = "1.6.0"
2
+ VERSION = "1.7.0"
3
3
  end
@@ -7,10 +7,10 @@ Gem::Specification.new do |spec|
7
7
  spec.name = "sassc"
8
8
  spec.version = SassC::VERSION
9
9
  spec.authors = ["Ryan Boland"]
10
- spec.email = ["bolandryanm@gmail.com"]
10
+ spec.email = ["ryan@tanookilabs.com"]
11
11
  spec.summary = "Use libsass with Ruby!"
12
12
  spec.description = "Use libsass with Ruby!"
13
- spec.homepage = "https://github.com/bolandrm/sassc-ruby"
13
+ spec.homepage = "https://github.com/sass/sassc-ruby"
14
14
  spec.license = "MIT"
15
15
 
16
16
  spec.files = `git ls-files -z`.split("\x0")
@@ -64,6 +64,34 @@ foo {
64
64
  SCSS
65
65
  end
66
66
 
67
+ def test_precision
68
+ template = <<-SCSS
69
+ $var: 1;
70
+ .foo {
71
+ baz: $var / 3; }
72
+ SCSS
73
+ expected_output = <<-CSS
74
+ .foo {
75
+ baz: 0.33333333; }
76
+ CSS
77
+ output = Engine.new(template, precision: 8).render
78
+ assert_equal expected_output, output
79
+ end
80
+
81
+ def test_precision_not_specified
82
+ template = <<-SCSS
83
+ $var: 1;
84
+ .foo {
85
+ baz: $var / 3; }
86
+ SCSS
87
+ expected_output = <<-CSS
88
+ .foo {
89
+ baz: 0.33333; }
90
+ CSS
91
+ output = Engine.new(template).render
92
+ assert_equal expected_output, output
93
+ end
94
+
67
95
  def test_dependency_filenames_are_reported
68
96
  temp_file("not_included.scss", "$size: 30px;")
69
97
  temp_file("import_parent.scss", "$size: 30px;")
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sassc
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.0
4
+ version: 1.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ryan Boland
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-07-29 00:00:00.000000000 Z
11
+ date: 2015-09-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
@@ -124,7 +124,7 @@ dependencies:
124
124
  version: 3.3.0
125
125
  description: Use libsass with Ruby!
126
126
  email:
127
- - bolandryanm@gmail.com
127
+ - ryan@tanookilabs.com
128
128
  executables: []
129
129
  extensions:
130
130
  - ext/Rakefile
@@ -317,7 +317,7 @@ files:
317
317
  - test/output_style_test.rb
318
318
  - test/sass_2_scss_test.rb
319
319
  - test/test_helper.rb
320
- homepage: https://github.com/bolandrm/sassc-ruby
320
+ homepage: https://github.com/sass/sassc-ruby
321
321
  licenses:
322
322
  - MIT
323
323
  metadata: {}