Last modified: 2012-09-02 19:43:36 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T41909, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 39909 - [Regression] mediawiki.user: getGroups broken
[Regression] mediawiki.user: getGroups broken
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
JavaScript (Other open bugs)
1.20.x
All All
: Normal major (vote)
: ---
Assigned To: Krinkle
: code-update-regression
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-09-02 13:42 UTC by Sam Reed (reedy)
Modified: 2012-09-02 19:43 UTC (History)
2 users (show)

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


Attachments

Description Sam Reed (reedy) 2012-09-02 13:42:34 UTC
Due to a change in the code used by the api...

Tests completed in 2835 milliseconds.
665 tests of 666 passed, 1 failed.
mediawiki.user: getGroups (1, 2, 3)Rerun
"*"" is the first group
Expected: 	
"*"
Result: 	
"bureaucrat"
Diff: 	
"*" "bureaucrat" 
Source: 	
    at Object.<anonymous> (http://192.168.0.190/w/tests/qunit/suites/resources/mediawiki/mediawiki.user.test.js:40:10)
    at fire (http://192.168.0.190/w/load.php?debug=true&lang=en-gb&modules=jquery%2Cmediawiki&only=scripts&skin=vector&version=20120902T132758Z:974:30)
    at Object.self.fireWith (http://192.168.0.190/w/load.php?debug=true&lang=en-gb&modules=jquery%2Cmediawiki&only=scripts&skin=vector&version=20120902T132758Z:1082:7)
    at Object.self.fire (http://192.168.0.190/w/load.php?debug=true&lang=en-gb&modules=jquery%2Cmediawiki&only=scripts&skin=vector&version=20120902T132758Z:1089:10)
    at Object.<anonymous> (http://192.168.0.190/w/resources/mediawiki/mediawiki.user.js:43:22)
    at fire (http://192.168.0.190/w/load.php?debug=true&lang=en-gb&modules=jquery%2Cmediawiki&only=scripts&skin=vector&version=20120902T132758Z:974:30)
    at Object.self.fireWith (http://192.168.0.190/w/load.php?debug=true&lang=en-gb&modules=jquery%2Cmediawiki&only=scripts&skin=vector&version=20120902T132758Z:1082:7)



http://192.168.0.190/w/api.php?action=query&meta=userinfo&uiprop=groups

<?xml version="1.0"?>
<api>
  <query>
    <userinfo id="1" name="Reedy">
      <groups>
        <g>bureaucrat</g>
        <g>checkuser</g>
        <g>svnadmins</g>
        <g>sysop</g>
        <g>*</g>
        <g>user</g>
        <g>autoconfirmed</g>
      </groups>
    </userinfo>
  </query>
</api>
Comment 1 Krinkle 2012-09-02 19:35:43 UTC
Fixing...

groups[0] should be groups.sort()[0] (like the other assertion does)
Comment 2 Krinkle 2012-09-02 19:43:36 UTC
Fixed in Id72b0550e5c0e1ae5454005f9245d1d542fc2e46.

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


Navigation
Links