Conversation
Update phpunit 7. Fix compile code like: @at-root a#{&} { }
There was a problem hiding this comment.
As far as I can tell, this does seem to fix #616, but I think there's at least an issue with upgrading phpunit (I believe phpunit7 requires php^7.1, but scssphp only requires php>=5.4.0), and possibly some coding style issues listed below.
| "autoload-dev": { | ||
| "psr-4": { "Leafo\\ScssPhp\\Test\\": "tests/" } | ||
| "psr-4": { "Leafo\\ScssPhp\\Test\\": "tests/" }, | ||
| "classmap": [ |
| "require-dev": { | ||
| "squizlabs/php_codesniffer": "~2.5", | ||
| "phpunit/phpunit": "~4.6" | ||
| "phpunit/phpunit": "^7" |
There was a problem hiding this comment.
I believe phpunit7 requires php^7.1, but scssphp only requires php>=5.4.0
|
|
||
| $this->env = $this->filterWithout($envs, $without); | ||
| $newBlock = $this->spliceTree($envs, $block, $without); | ||
| if (isset($block->atrootParent)) |
There was a problem hiding this comment.
I'm not sure about this projects coding standard, but I'm pretty sure using {} is prefered even on single line considitionals.
| $this->throwParseError('unexpected }'); | ||
| } | ||
|
|
||
| // if ($block->type == Type::T_AT_ROOT || $block->type == Type::T_MIXIN || $block->type == Type::T_INCLUDE) { |
There was a problem hiding this comment.
I assume this commented code should just not be included, if its not in use.
| continue; | ||
| } | ||
| // self | ||
| // if ($this->literal('#{&}', true)) { |
There was a problem hiding this comment.
i assume unused commented code should just be removed
|
Merged #643 |
@kingyond mentions this fork in #616 (comment) but for some reason hasnt opend a PR. I think there's a couple issues with the fix, but I figure a PR will at least better organize discussion about it. @mind-bending-forks also notes that they believe this fixes #616 as well #616 (comment)