Files
openide/platform/statistics/test/com/intellij/internal/statistic/MachineIdManagerTest.kt
Roman Shevchenko cf2c0980d5 [platform] more stable machine ID detection methods and saner API
(cherry-picked from commit 5e1a84a75324da0e123a443132aa38ab70c2fdea)

IJ-CR-147524

GitOrigin-RevId: 4d8a0428aa62ab6503940be1e74c47071707e81b
2024-10-28 21:00:43 +00:00

21 lines
650 B
Kotlin

// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
package com.intellij.internal.statistic
import com.intellij.internal.statistic.eventLog.fus.MachineIdManager
import org.assertj.core.api.Assertions.assertThat
import org.junit.jupiter.api.Assertions.assertThrows
import org.junit.jupiter.api.Test
class MachineIdManagerTest {
@Test fun smoke() {
assertThat(MachineIdManager.getAnonymizedMachineId("test"))
.isNotNull
}
@Test fun contract() {
assertThrows(IllegalArgumentException::class.java) {
MachineIdManager.getAnonymizedMachineId("")
}
}
}