We actually count css selectors, not rules in compass stats
This commit is contained in:
parent
b4d6550135
commit
9888efdbc2
@ -277,21 +277,21 @@ Feature: Command Line
|
|||||||
Given I am using the existing project in test/fixtures/stylesheets/compass
|
Given I am using the existing project in test/fixtures/stylesheets/compass
|
||||||
When I run: compass stats
|
When I run: compass stats
|
||||||
Then I am told statistics for each file:
|
Then I am told statistics for each file:
|
||||||
| Filename | Rules | Properties | Mixins Defs | Mixins Used | CSS Rules | CSS Properties |
|
| Filename | Rules | Properties | Mixins Defs | Mixins Used | CSS Selectors | CSS Properties |
|
||||||
| sass/border_radius.scss | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
| sass/border_radius.scss | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
||||||
| sass/box.sass | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
| sass/box.sass | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
||||||
| sass/fonts.sass | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
| sass/fonts.sass | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
||||||
| sass/gradients.sass | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
| sass/gradients.sass | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
||||||
| sass/image_size.sass | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
| sass/image_size.sass | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
||||||
| sass/images.scss | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
| sass/images.scss | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
||||||
| sass/layout.sass | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
| sass/layout.sass | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
||||||
| sass/legacy_clearfix.scss | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
| sass/legacy_clearfix.scss | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
||||||
| sass/lists.scss | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
| sass/lists.scss | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
||||||
| sass/print.sass | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
| sass/print.sass | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
||||||
| sass/reset.sass | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
| sass/reset.sass | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
||||||
| sass/utilities.scss | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
| sass/utilities.scss | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
||||||
| ------------------------- | ----- | ---------- | -------------- | ----------- | --------- | -------------- |
|
| ------------------------- | ----- | ---------- | -------------- | ----------- | ------------- | -------------- |
|
||||||
| Total.* | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
| Total.* | \d+ | \d+ | \d+ | \d+ | \d+ | \d+ |
|
||||||
|
|
||||||
@listframeworks
|
@listframeworks
|
||||||
Scenario: List frameworks registered with compass
|
Scenario: List frameworks registered with compass
|
||||||
|
@ -34,13 +34,13 @@ module Compass
|
|||||||
compiler = new_compiler_instance
|
compiler = new_compiler_instance
|
||||||
sass_files = sorted_sass_files(compiler)
|
sass_files = sorted_sass_files(compiler)
|
||||||
total_label = "Total (#{sass_files.size} files):"
|
total_label = "Total (#{sass_files.size} files):"
|
||||||
rows = [[ :-, :-, :-, :-, :-, :-, :- ],
|
rows = [[ :-, :-, :-, :-, :-, :-, :- ],
|
||||||
[ 'Filename', 'Rules', 'Properties', 'Mixins Defs', 'Mixins Used', 'CSS Rules', 'CSS Properties' ],
|
[ 'Filename', 'Rules', 'Properties', 'Mixins Defs', 'Mixins Used', 'CSS Selectors', 'CSS Properties' ],
|
||||||
[ :-, :-, :-, :-, :-, :-, :- ]]
|
[ :-, :-, :-, :-, :-, :-, :- ]]
|
||||||
maximums = [ total_label.length, 5, 10, 14, 11, 9, 14 ]
|
maximums = [ total_label.length, 5, 10, 14, 11, 13, 14 ]
|
||||||
alignments = [ :left, :right, :right, :right, :right, :right, :right ]
|
alignments = [ :left, :right, :right, :right, :right, :right, :right ]
|
||||||
delimiters = [ ['| ', ' |'], [' ', ' |'], [' ', ' |'], [' ', ' |'], [' ', ' |'], [' ', ' |'], [' ', ' |'] ]
|
delimiters = [ ['| ', ' |'], [' ', ' |'], [' ', ' |'], [' ', ' |'], [' ', ' |'], [' ', ' |'], [' ', ' |'] ]
|
||||||
totals = [ total_label, 0, 0, 0, 0, 0, 0 ]
|
totals = [ total_label, 0, 0, 0, 0, 0, 0 ]
|
||||||
|
|
||||||
sass_files.each do |sass_file|
|
sass_files.each do |sass_file|
|
||||||
css_file = compiler.corresponding_css_file(sass_file) unless sass_file[0..0] == '_'
|
css_file = compiler.corresponding_css_file(sass_file) unless sass_file[0..0] == '_'
|
||||||
|
Loading…
Reference in New Issue
Block a user