本文整理汇总了PHP中ilLanguage::expects方法的典型用法代码示例。如果您正苦于以下问题:PHP ilLanguage::expects方法的具体用法?PHP ilLanguage::expects怎么用?PHP ilLanguage::expects使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ilLanguage
的用法示例。
在下文中一共展示了ilLanguage::expects方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: setUp
/**
*
*/
public function setUp()
{
vfsStreamWrapper::register();
$root = vfsStreamWrapper::setRoot(new vfsStreamDirectory('root'));
$customizing_dir = vfsStream::newDirectory('Customizing')->at($root);
$this->client_dir = vfsStream::newDirectory('clients/default/agreement')->at($customizing_dir);
$this->global_dir = vfsStream::newDirectory('global/agreement')->at($customizing_dir);
$this->lng = $this->getMockBuilder('ilLanguage')->disableOriginalConstructor()->getMock();
$this->lng->expects($this->any())->method('getLangKey')->will($this->returnValue('de'));
$this->lng->expects($this->any())->method('getDefaultLanguage')->will($this->returnValue('fr'));
$this->source_files = array(vfsStream::url(implode('/', array('root', 'Customizing', 'clients', 'default', 'agreement', 'agreement_' . $this->lng->getLangKey() . '.html'))) => $this->lng->getLangKey(), vfsStream::url(implode('/', array('root', 'Customizing', 'clients', 'default', 'agreement', 'agreement_' . $this->lng->getDefaultLanguage() . '.html'))) => $this->lng->getDefaultLanguage(), vfsStream::url(implode('/', array('root', 'Customizing', 'clients', 'default', 'agreement', 'agreement_en.html'))) => 'en', vfsStream::url(implode('/', array('root', 'Customizing', 'global', 'agreement', 'agreement_' . $this->lng->getLangKey() . '.html'))) => $this->lng->getLangKey(), vfsStream::url(implode('/', array('root', 'Customizing', 'global', 'agreement', 'agreement_' . $this->lng->getDefaultLanguage() . '.html'))) => $this->lng->getDefaultLanguage(), vfsStream::url(implode('/', array('root', 'Customizing', 'global', 'agreement', 'agreement_en.html'))) => 'en');
}