def getWikis(self, wikiId): ''' get the wikis ''' wikiuser = TestWikiUser.getSMW_WikiUser(wikiId) wikibot = WikiBot.ofWikiUser(wikiuser) wikiclient = WikiClient.ofWikiUser(wikiuser) return wikibot, wikiclient
def getSMWs(self, wikiId='smwcopy'): ''' get the alternative SMW access instances for the given wiki id ''' wikiuser = TestWikiUser.getSMW_WikiUser(wikiId) wikibot = WikiBot.ofWikiUser(wikiuser) wikiclient = WikiClient.ofWikiUser(wikiuser) smwbot = SMWBot(wikibot.site) smwclient = SMWClient(wikiclient.getSite()) return [smwbot, smwclient]
def getSMW(self, wikiId='orth', url='https://confident.dbis.rwth-aachen.de'): smw = None wikiclient = None wusers = WikiUser.getWikiUsers() if 'test' in wusers: wuser = wusers[wikiId] if wuser.url.startswith(url): wikiclient = WikiClient.ofWikiUser(wuser) smw = SMWClient(wikiclient.getSite()) return smw, wikiclient
def getWikiClient(self, wikiId='or'): ''' get the alternative SMW access instances for the given wiki id ''' wikiuser = TestWikiUser.getSMW_WikiUser(wikiId) wikiclient = WikiClient.ofWikiUser(wikiuser) return wikiclient
def getSMW_Wiki(wikiId="cr"): wikiuser = TestWikiCMS.getSMW_WikiUser(wikiId) wikiclient = WikiClient.ofWikiUser(wikiuser) return wikiclient