Adds missing actual implementations on iOS

This commit is contained in:
Vitor Pamplona
2026-02-17 19:00:24 -05:00
parent c4e3d99392
commit cf7bdef028
5 changed files with 122 additions and 23 deletions
@@ -170,7 +170,7 @@ class GiftWrapReceivingBenchmark {
wrap.pubKey.hexToByteArray(),
)
benchmarkRule.measureRepeated { assertNotNull(innerJson?.let { Event.fromJson(it) }) }
benchmarkRule.measureRepeated { assertNotNull(innerJson.let { Event.fromJson(it) }) }
}
@Test
@@ -205,6 +205,6 @@ class GiftWrapReceivingBenchmark {
seal.pubKey.hexToByteArray(),
)
benchmarkRule.measureRepeated { assertNotNull(innerJson?.let { Rumor.fromJson(it) }) }
benchmarkRule.measureRepeated { assertNotNull(innerJson.let { Rumor.fromJson(it) }) }
}
}
@@ -138,7 +138,7 @@ class GiftWrapSigningBenchmark {
benchmarkRule.measureRepeated {
runBlocking {
GiftWrapEvent.create(
event = seal!!,
event = seal,
recipientPubKey = receiver.pubKey,
)
}
@@ -0,0 +1,27 @@
/*
* Copyright (c) 2025 Vitor Pamplona
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to use,
* copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the
* Software, and to permit persons to whom the Software is furnished to do so,
* subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
* FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
* AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package com.vitorpamplona.quartz
actual class TestResourceLoader actual constructor() {
actual fun loadString(file: String): String {
TODO("Not yet implemented")
}
}
@@ -20,26 +20,6 @@
*/
package com.vitorpamplona.quartz
/**
* Copyright (c) 2025 Vitor Pamplona
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to use,
* copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the
* Software, and to permit persons to whom the Software is furnished to do so,
* subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
* FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
* AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
expect class TestResourceLoader() {
fun loadString(file: String): String
}
@@ -0,0 +1,92 @@
/*
* Copyright (c) 2025 Vitor Pamplona
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to use,
* copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the
* Software, and to permit persons to whom the Software is furnished to do so,
* subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
* FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
* AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package com.vitorpamplona.quartz.nip64Chess
actual class ChessEngine actual constructor() {
actual fun getFen(): String {
TODO("Not yet implemented")
}
actual fun loadFen(fen: String) {
}
actual fun reset() {
}
actual fun makeMove(san: String): MoveResult {
TODO("Not yet implemented")
}
actual fun makeMove(
from: String,
to: String,
promotion: PieceType?,
): MoveResult {
TODO("Not yet implemented")
}
actual fun getLegalMoves(): List<String> {
TODO("Not yet implemented")
}
actual fun getLegalMovesFrom(square: String): List<String> {
TODO("Not yet implemented")
}
actual fun isLegalMove(san: String): Boolean {
TODO("Not yet implemented")
}
actual fun isLegalMove(
from: String,
to: String,
promotion: PieceType?,
): Boolean {
TODO("Not yet implemented")
}
actual fun isCheckmate(): Boolean {
TODO("Not yet implemented")
}
actual fun isStalemate(): Boolean {
TODO("Not yet implemented")
}
actual fun isInCheck(): Boolean {
TODO("Not yet implemented")
}
actual fun undoMove() {
}
actual fun getPosition(): ChessPosition {
TODO("Not yet implemented")
}
actual fun getSideToMove(): Color {
TODO("Not yet implemented")
}
actual fun getMoveHistory(): List<String> {
TODO("Not yet implemented")
}
}