Improved version of file extension test

Hi,

I got rid of the loop for file extension test. Instead just use the good old intersection to check the file extension. And added a test for that to the `rspec`-testsuite. Forgot that to add yesterday evening.

Besides:
Ruby outputs warnings about `has_extname? *%w(.gif .png .jpg .jpeg .webp .svg .svgz)` without extra parentheses. I added those ones to make it happy.

```
ruby -c -w asset.rb
# => lib/middleman-sprockets/asset.rb:162: warning: `*' interpreted as argument prefix
# => Syntax OK
``