mirror of
https://github.com/ethauvin/kobalt.git
synced 2025-04-26 08:27:12 -07:00
Fix source jar file.
This commit is contained in:
parent
2f840a44fd
commit
986f1b01be
7 changed files with 49 additions and 30 deletions
|
@ -1,5 +1,8 @@
|
|||
package com.beust.kobalt
|
||||
|
||||
import com.beust.kobalt.misc.From
|
||||
import com.beust.kobalt.misc.IncludedFile
|
||||
import com.beust.kobalt.misc.To
|
||||
import org.testng.Assert
|
||||
import org.testng.annotations.BeforeClass
|
||||
import org.testng.annotations.DataProvider
|
||||
|
@ -45,7 +48,16 @@ class IncludeExcludeTest : KobaltTest() {
|
|||
@Test(dataProvider = "dp")
|
||||
fun shouldInclude(root: File, includedSpec: List<String>, excludedSpec: List<String>, expectedFiles: List<String>) {
|
||||
val g = IFileSpec.GlobSpec(includedSpec)
|
||||
val files = g.toFiles(root.path, excludedSpec.map { Glob(it) })
|
||||
val files = g.toFiles("", root.path, excludedSpec.map { Glob(it) })
|
||||
Assert.assertEquals(files.map { it.name }, expectedFiles)
|
||||
}
|
||||
|
||||
@Test
|
||||
private fun f() {
|
||||
val spec = IFileSpec.GlobSpec("src/**")
|
||||
val files = spec.toFiles(homeDir("kotlin/kobalt"), "src/main/kotlin")
|
||||
val inc = IncludedFile(From("src/main/kotlin"), To(""), listOf(IFileSpec.GlobSpec("**")))
|
||||
// val files = inc.allFromFiles(homeDir("kotlin/kobalt"))
|
||||
println("FILES: " + files)
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue