asciidisco / grunt-imagine

Grunt tasks for optimizing & inlining images
MIT License
153 stars 21 forks source link

generating background-image url with staticImagePath and mapname #65

Closed antonia-rose closed 9 years ago

antonia-rose commented 9 years ago

Fix for issue https://github.com/asciidisco/grunt-imagine/issues/64. We only need basename of spriteMap instead of whole path

asciidisco commented 9 years ago

\o/ Thank you. Will review & merge later today.

LaurentGoderre commented 9 years ago

@soophie would you be able to provide a unit test as well?

antonia-rose commented 9 years ago

@LaurentGoderre I'll take a look for a unit test, but I can't promise ;)

asciidisco commented 9 years ago

@soophie If you need help, just ping me. I should have some time during easter.

antonia-rose commented 9 years ago

Great, thanks! I would like to get in touch with unit tests, but for now I'm not sure, what I want to test. :-)

LaurentGoderre commented 9 years ago

@soophie you can use the problem you are encountering as a test

https://github.com/asciidisco/grunt-imagine/issues/64#issuecomment-77888978

asciidisco commented 9 years ago

@soophie I´m going to take a look into this in the next 2 to 3 days

LaurentGoderre commented 9 years ago

This has become a priority for us as well. I will create a test for this.

LaurentGoderre commented 9 years ago

Turns out this project doesn't have as much unit testing as I thought. I tested it and it works like a charm!

antonia-rose commented 9 years ago

Great, thanks! It was a bit tricky for me to write tests, because the existing tests weren't very helpful. and I have to say: I never wrote tests ;)

LaurentGoderre commented 9 years ago

It is a bit daunting to start I must admit.

LaurentGoderre commented 9 years ago

@soophie I just released your fix as v0.3.54! Thanks a lot you saved me a lot of time there!