Skip to content

Commit fcd3c42

Browse files
committed
adding a test
1 parent 8e4c402 commit fcd3c42

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

test/integration/asset/pipeline/grails/LinkGeneratorSpec.groovy

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,17 @@ class LinkGeneratorSpec extends IntegrationSpec {
5050
resource == "http://localhost:8080/assets/grails_logo.png"
5151
}
5252

53+
def "find asset path only with no file"() {
54+
given: "A LinkGenerator pointed to a directory"
55+
AssetPipelineConfigHolder.manifest = null
56+
def linkGenerator = new LinkGenerator("http://localhost:8080")
57+
linkGenerator.assetProcessorService = assetProcessorService
58+
when:
59+
def resource = linkGenerator.resource(dir: 'asset-pipeline/test')
60+
then:
61+
resource != null
62+
}
63+
5364
def "finds asset in precompiled (prod) mode"() {
5465
given: "A LinkGenerator and an image"
5566
def linkGenerator = new LinkGenerator("http://localhost:8080")

0 commit comments

Comments
 (0)