Hoo man has uploaded a new change for review. ( https://gerrit.wikimedia.org/r/386111 )
Change subject: Minor clean up for Lua tests ...................................................................... Minor clean up for Lua tests Also add a new test case I used when looking after T173194#3702372 (which wasn't needed… but it shouldn't harm). Change-Id: I742f40ae892563debe7cd2ccbb0ccda55789274c --- M client/tests/phpunit/includes/DataAccess/Scribunto/LuaWikibaseLibraryTests.lua 1 file changed, 7 insertions(+), 3 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase refs/changes/11/386111/1 diff --git a/client/tests/phpunit/includes/DataAccess/Scribunto/LuaWikibaseLibraryTests.lua b/client/tests/phpunit/includes/DataAccess/Scribunto/LuaWikibaseLibraryTests.lua index 73de15f..1fbbe3a 100644 --- a/client/tests/phpunit/includes/DataAccess/Scribunto/LuaWikibaseLibraryTests.lua +++ b/client/tests/phpunit/includes/DataAccess/Scribunto/LuaWikibaseLibraryTests.lua @@ -118,7 +118,7 @@ args = { 0, 'P12' }, expect = "bad argument #1 to 'getBestStatements' (string expected, got number)" }, - { name = 'mw.wikibase.getBestStatements (entityId must be string)', func = mw.wikibase.getBestStatements, type='ToString', + { name = 'mw.wikibase.getBestStatements (propertyId must be string)', func = mw.wikibase.getBestStatements, type='ToString', args = { 'Q2', 12 }, expect = "bad argument #2 to 'getBestStatements' (string expected, got number)" }, @@ -132,7 +132,7 @@ args = { 0, 'P12' }, expect = "bad argument #1 to 'getAllStatements' (string expected, got number)" }, - { name = 'mw.wikibase.getAllStatements (entityId must be string)', func = mw.wikibase.getAllStatements, type='ToString', + { name = 'mw.wikibase.getAllStatements (propertyId must be string)', func = mw.wikibase.getAllStatements, type='ToString', args = { 'Q2', 12 }, expect = "bad argument #2 to 'getAllStatements' (string expected, got number)" }, @@ -263,10 +263,14 @@ args = { 'Q32488' }, expect = { nil } }, - { name = 'mw.wikibase.sitelink (with global site id)', func = mw.wikibase.sitelink, type='ToString', + { name = 'mw.wikibase.sitelink (with global site id 1)', func = mw.wikibase.sitelink, type='ToString', args = { 'Q32487', 'fooSiteId' }, expect = { 'FooBarFoo' } }, + { name = 'mw.wikibase.sitelink (with global site id 2)', func = mw.wikibase.sitelink, type='ToString', + args = { 'Q32487', 'dewiki' }, + expect = { 'WikibaseClientDataAccessTest' } + }, { name = 'mw.wikibase.sitelink (with global site id not found)', func = mw.wikibase.sitelink, type='ToString', args = { 'Q32487', 'does-not-exist' }, expect = { nil } -- To view, visit https://gerrit.wikimedia.org/r/386111 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I742f40ae892563debe7cd2ccbb0ccda55789274c Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Wikibase Gerrit-Branch: master Gerrit-Owner: Hoo man <h...@online.de> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits