Rename tests consistently with the naming convention
authorVitaliy.Bibaev <vitaliy.bibaev@jetbrains.com>
Tue, 19 Dec 2017 10:02:48 +0000 (13:02 +0300)
committerVitaliy.Bibaev <vitaliy.bibaev@jetbrains.com>
Tue, 19 Dec 2017 10:02:48 +0000 (13:02 +0300)
plugins/stats-collector/log-events/src/test/kotlin/com/intellij/stats/completion/EventStreamValidatorTest.kt
plugins/stats-collector/test/com/intellij/stats/completion/storage/StorageTest.kt

index 6a744a614ba511214dd0c249babd29d41b36a53d..f9dd3ff1309a69f7e371aad55b0e482df9c1e83f 100644 (file)
@@ -28,19 +28,19 @@ private fun List<LogEvent>.serialize(): List<String> = map { LogEventSerializer.
 class EventStreamValidatorTest {
 
     @Test
-    fun simple_sequence_of_actions() {
+    fun `simple sequence of actions`() {
         val list = listOf(LogEventFixtures.completion_started_3_items_shown, LogEventFixtures.explicit_select_position_0)
         validate(list, list.map { LogEventSerializer.toString(it) }, emptyList())
     }
 
     @Test
-    fun sample_error_sequence_of_actions() {
+    fun `sample error sequence of actions`() {
         val list = listOf(LogEventFixtures.completion_started_3_items_shown, LogEventFixtures.explicit_select_position_1)
         validate(list, expectedOut = emptyList(), expectedErr = list.serialize())
     }
 
     @Test
-    fun up_down_actions() {
+    fun `up down actions`() {
         val list = listOf(
                 LogEventFixtures.completion_started_3_items_shown,
                 LogEventFixtures.down_event_new_pos_1,
@@ -53,7 +53,7 @@ class EventStreamValidatorTest {
     }
 
     @Test
-    fun up_down_actions_wrong() {
+    fun `up down actions wrong`() {
         val list = listOf(
                 LogEventFixtures.completion_started_3_items_shown,
                 LogEventFixtures.down_event_new_pos_1,
@@ -66,7 +66,7 @@ class EventStreamValidatorTest {
     }
 
     @Test
-    fun selected_by_typing_relaxed_conditions() {
+    fun `selected by typing relaxed conditions`() {
         val list = listOf(
                 LogEventFixtures.completion_started_3_items_shown,
                 LogEventFixtures.type_event_current_pos_0_left_ids_1_2,
@@ -77,7 +77,7 @@ class EventStreamValidatorTest {
     }
 
     @Test
-    fun selected_by_typing_error() {
+    fun `selected by typing error`() {
         val list = listOf(
                 LogEventFixtures.completion_started_3_items_shown,
                 LogEventFixtures.type_event_current_pos_0_left_ids_0_1,
index 2d06ca5bd7f0269854f85c2aa0754565a9be2896..7b7ee5c7f3ff63f3d71219b57dcb1296334cde7a 100644 (file)
@@ -42,7 +42,7 @@ class FilesProviderTest {
     }
     
     @Test
-    fun test_three_new_files_created() {
+    fun `test three new files created`() {
         provider.getUniqueFile().createNewFile()
         provider.getUniqueFile().createNewFile()
         provider.getUniqueFile().createNewFile()
@@ -72,14 +72,14 @@ class AsciiMessageStorageTest {
     }
 
     @Test
-    fun test_size_with_new_lines() {
+    fun `test size with new lines`() {
         val line = "text"
         storage.appendLine(line)
         assertThat(storage.sizeWithNewLine("")).isEqualTo(line.length + 2 * System.lineSeparator().length)
     }
     
     @Test
-    fun test_size_is_same_as_file_size() {
+    fun `test size is same as file size`() {
         val line = "text"
         storage.appendLine(line)
         storage.appendLine(line)
@@ -90,8 +90,6 @@ class AsciiMessageStorageTest {
         storage.dump(tmpFile)
         assertThat(tmpFile.length()).isEqualTo(expectedSize.toLong())
     }
-    
-    
 }
 
 
@@ -116,7 +114,7 @@ class FileLoggerTest {
     }
 
     @Test
-    fun test_chunk_is_around_256Kb() {
+    fun `test chunk is around 256Kb`() {
         val bytesToWrite = 1024 * 200
         val text = StringUtil.repeat("c", bytesToWrite)
         fileLogger.println(text)
@@ -131,7 +129,7 @@ class FileLoggerTest {
     }
     
     @Test
-    fun test_multiple_chunks() {
+    fun `test multiple chunks`() {
         writeKb(1024)
 
         val files = filesProvider.getDataFiles()
@@ -142,7 +140,7 @@ class FileLoggerTest {
 
 
     @Test
-    fun test_delete_old_stuff() {
+    fun `test delete old stuff`() {
         writeKb(4096)
 
         var files = filesProvider.getDataFiles()
@@ -178,5 +176,4 @@ class FileLoggerTest {
         }
         fileLogger.dispose()
     }
-
 }
\ No newline at end of file