2020-08-28 16:31:13 +00:00
|
|
|
package com.htmlism.nescant
|
|
|
|
package dsl
|
|
|
|
|
2023-10-03 20:15:10 +00:00
|
|
|
import org.scalatest.flatspec.*
|
|
|
|
import org.scalatest.matchers.*
|
2020-08-28 16:31:13 +00:00
|
|
|
|
2022-02-14 23:11:45 +00:00
|
|
|
class ByteSinkSpec extends AnyFlatSpec with should.Matchers:
|
2023-06-13 18:01:45 +00:00
|
|
|
"A zero page address" should "be a byte-wide sync" in:
|
2020-08-28 16:31:13 +00:00
|
|
|
123.z.write(456)
|
|
|
|
|
2023-06-13 18:01:45 +00:00
|
|
|
"A global address" should "be a byte-wide sync" in:
|
2020-08-28 16:31:13 +00:00
|
|
|
123.g.write(456)
|
|
|
|
|
2023-06-13 18:01:45 +00:00
|
|
|
"A read write location" should "be a byte-wide sync" in:
|
2020-08-28 16:31:13 +00:00
|
|
|
val sink = ReadWriteLocation[Int]("", 0.z)
|
|
|
|
|
|
|
|
sink.write(456)
|