Last modified: 2012-07-31 08:03:09 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 27395 - Write unit tests for JavaScriptMinifier, CSSMin and CSSJanus
Write unit tests for JavaScriptMinifier, CSSMin and CSSJanus
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
ResourceLoader (Other open bugs)
unspecified
All All
: Normal enhancement (vote)
: ---
Assigned To: Krinkle
:
Depends on:
Blocks: 27528
  Show dependency treegraph
 
Reported: 2011-02-14 12:31 UTC by Sam Reed (reedy)
Modified: 2012-07-31 08:03 UTC (History)
2 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Sam Reed (reedy) 2011-02-14 12:31:01 UTC
Write unit tests for JS/CSS minifier. As we find the odd boundary/wrong minification, they should be logged to prevent regressions
Comment 1 Sam Reed (reedy) 2011-02-14 12:33:52 UTC
bug 26931
bug 27046
bug 27054
bug 27052

etc should be test cases
Comment 2 Max Semenik 2011-02-24 13:11:37 UTC
I added a basic testing framework for JS minifier in r82648, but can't really cover all cases because those regexes are write-only.
Comment 3 Bugmeister Bot 2011-08-19 19:12:57 UTC
Unassigning default assignments. http://article.gmane.org/gmane.science.linguistics.wikipedia.technical/54734
Comment 4 Krinkle 2012-06-20 01:19:20 UTC
(In reply to comment #2)
> I added a basic testing framework for JS minifier in r82648, but can't really
> cover all cases because those regexes are write-only.

Can you elaborate what you mean? Also, why are the js snippets in separate files?
Comment 5 Krinkle 2012-06-20 01:22:16 UTC
(In reply to comment #4)
> (In reply to comment #2)
> > I added a basic testing framework for JS minifier in r82648, but can't really
> > cover all cases because those regexes are write-only.
> 
> Can you elaborate what you mean? Also, why are the js snippets in separate
> files?

Ah, looks like it has changed in the mean time. We've got a pretty good coverage of CSS minification tests now:
https://gerrit.wikimedia.org/r/gitweb?p=mediawiki/core.git;a=tree;f=tests/phpunit/includes/libs;h=779b41ecc126eb57dd88cbf523d15b8b9a549ac0;hb=HEAD

Just need some for CSS.
Comment 6 Krinkle 2012-06-20 01:57:16 UTC
(In reply to comment #1)
> bug 26931
> bug 27046
> bug 27054
> bug 27052
> 

Added test cases for bug 26931 and bug 27046 in I7a4df097108ec05bc58d5a110329e13ff9587c8a.

bug 27054 wasn't a bug in the minifier and has been solved in ResourceLoader). 

Working on CSSMin and CSSJanus now.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links