vcs test: use getComponent to get component instead of calling ServiceManager
authorKirill Likhodedov <Kirill.Likhodedov@jetbrains.com>
Tue, 3 May 2016 14:07:51 +0000 (17:07 +0300)
committerKirill Likhodedov <Kirill.Likhodedov@jetbrains.com>
Tue, 3 May 2016 14:07:51 +0000 (17:07 +0300)
platform/vcs-tests/testSrc/com/intellij/vcs/VcsDirtyScopeManagerTest.kt

index cc06caf9e6ab68e1e6db31b01bf70c5e7111286b..10063732052eb03e02525a3c51fc00068584107f 100644 (file)
@@ -16,7 +16,6 @@
 package com.intellij.vcs
 
 import com.intellij.openapi.application.ApplicationManager
-import com.intellij.openapi.components.service
 import com.intellij.openapi.vcs.AbstractVcs
 import com.intellij.openapi.vcs.FilePath
 import com.intellij.openapi.vcs.ProjectLevelVcsManager
@@ -144,7 +143,7 @@ class VcsDirtyScopeManagerTest : VcsPlatformTest() {
   }
 
   private fun disableVcsDirtyScopeVfsListener() {
-    myProject.service<VcsDirtyScopeVfsListener>().setForbid(true)
+    myProject.getComponent(VcsDirtyScopeVfsListener::class.java).setForbid(true)
   }
 
   private fun disableChangeListManager() {