Skip to content

Commit c93d2c8

Browse files
committed
fixes tests
1 parent 54c7d61 commit c93d2c8

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

templates/dashboard.html.twig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
</v-card>
3737

3838
<v-card light color="grey">
39-
<v-card-text class="recipe-holder">
39+
<v-card-text class="recipe-holder">LocalRecipeCompiler
4040
<div class="text-xs-center" v-if="!dataLoaded">
4141
<v-progress-circular center :indeterminate="true" color="white" height="4"></v-progress-circular>
4242
</div>

tests/Service/Compiler/LocalRecipeCompilerTest.php

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
use App\Entity\Recipe;
66
use App\Service\Compiler\LocalRecipeCompiler;
7+
use App\Service\RecipePublicUrlResolver;
78
use App\Service\RecipeRepoManager;
89
use App\Tests\RepoAwareTestCase;
910

@@ -27,7 +28,12 @@ function setUp()
2728
->willReturn([$repoStub]);
2829
$repoManagerStub->expects($this->once())->method('getConfiguredRepos');
2930

30-
$this->compiler = new LocalRecipeCompiler($repoManagerStub);
31+
$urlResolverStub = $this->createMock(RecipePublicUrlResolver::class);
32+
$urlResolverStub->method('resolveUrl')
33+
->willReturn('testUrl');
34+
$urlResolverStub->expects($this->exactly(5))->method('resolveUrl');
35+
36+
$this->compiler = new LocalRecipeCompiler($repoManagerStub, $urlResolverStub);
3137
}
3238

3339
function testLocalRecipesAreLoadedProperly()
@@ -92,4 +98,4 @@ function packageResolvingTestProvider()
9298
];
9399
}
94100

95-
}
101+
}

0 commit comments

Comments
 (0)