Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
ComTest.IntelliJ
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
tie
Työkalut
ComTest.IntelliJ
Commits
3ef872e2
Commit
3ef872e2
authored
2 years ago
by
Denis Zhidkikh
Browse files
Options
Downloads
Patches
Plain Diff
Rider: Fix running unit tests after ComTest run
parent
5ab231c5
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
rider/src/main/kotlin/fi/jyu/intellij/comtest/rider/actions/ComTestGenerateDotNetSolutionAction.kt
+15
-15
15 additions, 15 deletions
...test/rider/actions/ComTestGenerateDotNetSolutionAction.kt
with
15 additions
and
15 deletions
rider/src/main/kotlin/fi/jyu/intellij/comtest/rider/actions/ComTestGenerateDotNetSolutionAction.kt
+
15
−
15
View file @
3ef872e2
...
@@ -2,6 +2,10 @@ package fi.jyu.intellij.comtest.rider.actions
...
@@ -2,6 +2,10 @@ package fi.jyu.intellij.comtest.rider.actions
import
com.intellij.openapi.actionSystem.AnAction
import
com.intellij.openapi.actionSystem.AnAction
import
com.intellij.openapi.actionSystem.AnActionEvent
import
com.intellij.openapi.actionSystem.AnActionEvent
import
com.intellij.openapi.actionSystem.ex.ActionManagerEx
import
com.jetbrains.rd.platform.util.lifetime
import
com.jetbrains.rider.model.solutionAnalysisModel
import
com.jetbrains.rider.projectView.solution
import
fi.jyu.intellij.comtest.common.util.runWithRefresh
import
fi.jyu.intellij.comtest.common.util.runWithRefresh
import
fi.jyu.intellij.comtest.rider.ComTestRunner
import
fi.jyu.intellij.comtest.rider.ComTestRunner
import
fi.jyu.intellij.comtest.rider.util.hasRiderSolution
import
fi.jyu.intellij.comtest.rider.util.hasRiderSolution
...
@@ -18,21 +22,17 @@ class ComTestGenerateDotNetSolutionAction : AnAction() {
...
@@ -18,21 +22,17 @@ class ComTestGenerateDotNetSolutionAction : AnAction() {
ComTestRunner
.
generateForDotNetSln
(
proj
)
ComTestRunner
.
generateForDotNetSln
(
proj
)
}
}
// // FIXME: Waiting for project reload and running unit tests automatically. Right now timing seems to be difficult
// csproj change will trigger assembly analysis
// VfsWatchRootHost.getInstance(proj).sync()
// Wait for it to finish and then trigger unit test discovery
// SolutionLifecycleHost.getInstance(proj).waitSolutionBuilderIsReady()
val
l
=
proj
.
lifetime
.
createNested
()
// // https://dploeger.github.io/intellij-api-doc/com/intellij/openapi/project/DumbService.html
proj
.
solution
.
solutionAnalysisModel
.
ready
.
change
.
advise
(
l
)
{
// val ds = proj.service<DumbService>()
if
(
it
)
{
// WorkspaceModelUpdater.getInstance(proj).syncIfPossible()
l
.
terminate
(
true
)
// thread {
val
act
=
ActionManagerEx
.
getInstanceEx
().
getAction
(
"RiderUnitTestRunSolutionAction"
)
!!
// Thread.sleep(500)
act
.
update
(
e
)
// ds.waitForSmartMode()
act
.
actionPerformed
(
e
)
// ds.smartInvokeLater({
}
// val act = ActionManagerEx.getInstanceEx().getAction("RiderUnitTestRunSolutionAction")!!
}
// act.update(e)
// act.actionPerformed(e)
// }, ModalityState.NON_MODAL)
// }
}
}
override
fun
update
(
e
:
AnActionEvent
)
{
override
fun
update
(
e
:
AnActionEvent
)
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment