Glavin001 / atom-preview

:construction: (NO LONGER MAINTAINED) :construction: - :eyeglasses: Ultimate previewer of source code in Atom.
https://atom.io/packages/preview
MIT License
51 stars 23 forks source link

Support mixed case file extensions #55

Closed jordanbtucker closed 10 years ago

jordanbtucker commented 10 years ago

Ignore case so that .djs, .DJS, and .Djs all work.

Also, no need to match entire string, just the end. See http://jsperf.com/regex-match-all-or-end-only regarding performance gains.

Glavin001 commented 10 years ago

Exceptional. Thank you, @jordanbtucker! And also thanks for the jsperf. Will test, merge, and publish in a few minutes.

Glavin001 commented 10 years ago

Published as v0.10.4 :+1:

jordanbtucker commented 10 years ago

I forgot to write a test case for this. Does Preview actually run any tests besides the one in preview-spec.coffee?

Glavin001 commented 10 years ago

Not yet; @ddavison is working on that for #17.

ddavison commented 10 years ago

eventually that will be a requirement, and listed within the contribution guidelines

Glavin001 commented 10 years ago

I'm looking forward to having Travis CI testing Pull Requests and a complete Testing framework to verify up our non-breaking changes. It will definitely become a requirement for contributors. I think we could have a more open-ended test for renderers, such that it would run through a directory (supported_samples/) of source code files and pass them to the Previewing engine with the text, filepath, and grammar. With that in mind, in your case, @jordanbtucker, you would not even have a test to write :+1:.