From 5458bd367740773e0a25f24d638fb679c88ddc23 Mon Sep 17 00:00:00 2001 From: "liubar.pa" Date: Thu, 4 May 2023 02:30:03 +0300 Subject: [PATCH] SNRK-70: better arguments in buildDocument --- snark-document-builder/src/main/kotlin/DocumentBuilder.kt | 4 +--- snark-document-builder/src/test/kotlin/DocumentBuilder.kt | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/snark-document-builder/src/main/kotlin/DocumentBuilder.kt b/snark-document-builder/src/main/kotlin/DocumentBuilder.kt index 551ba70..1b1ebe5 100644 --- a/snark-document-builder/src/main/kotlin/DocumentBuilder.kt +++ b/snark-document-builder/src/main/kotlin/DocumentBuilder.kt @@ -2,13 +2,11 @@ package documentBuilder import com.fasterxml.jackson.core.io.BigDecimalParser import space.kscience.snark.storage.* -import space.kscience.snark.storage.local.LocalDirectory import java.nio.file.Path val DEFAULT_DOCUMENT_ROOT = "main.md" -public suspend fun buildDocument(documentPath: String) { - val documentDirectory: Directory = LocalDirectory(documentPath) +public suspend fun buildDocument(documentDirectory: Directory) { val documentRoot = documentDirectory.get(DEFAULT_DOCUMENT_ROOT) TODO() diff --git a/snark-document-builder/src/test/kotlin/DocumentBuilder.kt b/snark-document-builder/src/test/kotlin/DocumentBuilder.kt index 6c16cc9..95c6002 100644 --- a/snark-document-builder/src/test/kotlin/DocumentBuilder.kt +++ b/snark-document-builder/src/test/kotlin/DocumentBuilder.kt @@ -6,6 +6,6 @@ import kotlinx.coroutines.runBlocking class SomeTest { @Test fun justWorks() = runBlocking { - buildDocument("../example") + // buildDocument(Directory("../example")) } }