test case for #30
code style
minified version
fixes #30