public function it_translate_the_given_category_in_the_given_language(Compiler $compiler, Repository $config)
{
$filePath = 'cached/file';
$categoryToTranslate = 'categoryName';
$translations = ['it' => [$categoryToTranslate => 'translation']];
$compiler->getFilePath()->shouldBeCalled()->willReturn($filePath);
$config->get('notifynder.translations')->shouldBeCalled()->willReturn($translations);
$compiler->cacheFile($translations)->shouldBeCalled();
$this->translate('it', $categoryToTranslate)->shouldReturn($translations['it'][$categoryToTranslate]);
}