Skip to content

Commit

Permalink
test updated to work with JS
Browse files Browse the repository at this point in the history
  • Loading branch information
morisil committed Sep 6, 2024
1 parent 27fd9e3 commit 6861d12
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions xemantic-osc-api/src/commonTest/kotlin/type/OscWritingTest.kt
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@

package com.xemantic.osc.type

import com.xemantic.osc.ZERO
import com.xemantic.osc.writeOscToBytes
import com.xemantic.osc.util.ZERO
import com.xemantic.osc.util.writeOscToBytes
import io.kotest.assertions.throwables.shouldThrowWithMessage
import io.kotest.matchers.shouldBe
import kotlin.test.Test
Expand All @@ -30,7 +30,7 @@ class OscWritingTest {
fun shouldWriteString() {
writeOscToBytes {
string("OSC")
} shouldBe com.xemantic.osc.byteArrayOf('O', 'S', 'C', ZERO)
} shouldBe com.xemantic.osc.util.byteArrayOf('O', 'S', 'C', ZERO)
}

@Test
Expand Down Expand Up @@ -65,7 +65,7 @@ class OscWritingTest {
fun shouldWriteChar() {
writeOscToBytes {
char('a')
} shouldBe com.xemantic.osc.byteArrayOf(ZERO, ZERO, ZERO, 'a')
} shouldBe com.xemantic.osc.util.byteArrayOf(ZERO, ZERO, ZERO, 'a')
}

@Test
Expand Down Expand Up @@ -101,19 +101,19 @@ class OscWritingTest {

writeOscToBytes {
typeTag("f")
} shouldBe com.xemantic.osc.byteArrayOf(',', 'f', ZERO, ZERO)
} shouldBe com.xemantic.osc.util.byteArrayOf(',', 'f', ZERO, ZERO)

writeOscToBytes {
typeTag("fi")
} shouldBe com.xemantic.osc.byteArrayOf(',', 'f', 'i', ZERO)
} shouldBe com.xemantic.osc.util.byteArrayOf(',', 'f', 'i', ZERO)

writeOscToBytes {
typeTag("fis")
} shouldBe com.xemantic.osc.byteArrayOf(',', 'f', 'i', 's', ZERO, ZERO, ZERO, ZERO)
} shouldBe com.xemantic.osc.util.byteArrayOf(',', 'f', 'i', 's', ZERO, ZERO, ZERO, ZERO)

writeOscToBytes {
typeTag("fisc")
} shouldBe com.xemantic.osc.byteArrayOf(',', 'f', 'i', 's', 'c', ZERO, ZERO, ZERO)
} shouldBe com.xemantic.osc.util.byteArrayOf(',', 'f', 'i', 's', 'c', ZERO, ZERO, ZERO)

}

Expand Down

0 comments on commit 6861d12

Please sign in to comment.