dash ble tests: ktlintFormat

This commit is contained in:
Andrei Vereha 2021-03-14 16:00:59 +01:00
parent a94d6ce652
commit b71f065974
7 changed files with 24 additions and 29 deletions

View file

@ -2,7 +2,6 @@ package info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.comm.pair
import com.google.crypto.tink.subtle.X25519 import com.google.crypto.tink.subtle.X25519
import info.nightscout.androidaps.logging.AAPSLogger import info.nightscout.androidaps.logging.AAPSLogger
import info.nightscout.androidaps.logging.AAPSLoggerTest
import info.nightscout.androidaps.logging.LTag import info.nightscout.androidaps.logging.LTag
import info.nightscout.androidaps.plugins.pump.omnipod.dash.BuildConfig import info.nightscout.androidaps.plugins.pump.omnipod.dash.BuildConfig
import info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.comm.exceptions.MessageIOException import info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.comm.exceptions.MessageIOException
@ -12,7 +11,8 @@ import org.spongycastle.crypto.macs.CMac
import org.spongycastle.crypto.params.KeyParameter import org.spongycastle.crypto.params.KeyParameter
import java.security.SecureRandom import java.security.SecureRandom
class KeyExchange(private val aapsLogger: AAPSLogger, class KeyExchange(
private val aapsLogger: AAPSLogger,
var pdmPrivate: ByteArray = X25519.generatePrivateKey(), var pdmPrivate: ByteArray = X25519.generatePrivateKey(),
val pdmNonce: ByteArray = ByteArray(NONCE_SIZE) val pdmNonce: ByteArray = ByteArray(NONCE_SIZE)
) { ) {

View file

@ -1,9 +1,7 @@
package info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.comm.message package info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.comm.message
import android.app.Notification
import com.google.crypto.tink.subtle.Hex import com.google.crypto.tink.subtle.Hex
import info.nightscout.androidaps.logging.AAPSLoggerTest import info.nightscout.androidaps.logging.AAPSLoggerTest
import info.nightscout.androidaps.logging.LTag
import info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.comm.Id import info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.comm.Id
import info.nightscout.androidaps.utils.extensions.toHex import info.nightscout.androidaps.utils.extensions.toHex
import org.junit.Assert.* import org.junit.Assert.*

View file

@ -18,5 +18,3 @@ class PayloadJoinerTest {
assertEquals(payload, actual.toHex()) assertEquals(payload, actual.toHex())
} }
} }

View file

@ -2,7 +2,6 @@ package info.nightscout.androidaps.plugins.pump.omnipod.dash.driver.comm.pair
import info.nightscout.androidaps.logging.AAPSLoggerTest import info.nightscout.androidaps.logging.AAPSLoggerTest
import info.nightscout.androidaps.utils.extensions.toHex import info.nightscout.androidaps.utils.extensions.toHex
import org.junit.Assert
import org.junit.Assert.* import org.junit.Assert.*
import org.junit.Test import org.junit.Test
import org.spongycastle.util.encoders.Hex import org.spongycastle.util.encoders.Hex