Giter Club home page Giter Club logo

unitvisualizer's People

Contributors

matwein avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

clindbergh

unitvisualizer's Issues

Support for moving Groovy tests

Hello,

my tests are written in Groovy using the Spock framework. This also means that the tests are in the src/test/groovy source root. Unfortunately, the plugin does not move these Groovy test classes when the associated Java class is moved. Could you please have a look at this? Maybe the plugin is only looking for Java classes when searching for the associated test class?

Interestingly, the icon decorations are working properly for the Groovy tests. Even the Groovy test methods are properly recognized, although they often have names not matching the tested methods' names.

Tested with IntelliJ 2021.3.3 and UnitVisualizer 1.7.1

Moving of test-class doesn't work for subproject in gradle multi-project environment

Hello and thanks for this nice tool!

Unfortunately, the moving of tests along with their class doesn't seem to work for the subprojects of a gradle multi-project-build. (For simple projects and the root-project in multi the plugin works.)
The plugin also works in subprojects w.r.t. visualization of tested classes - the little symbol is displayed correctly (but although recognized, they aren't moved).

I was able to recreate the issue with IntelliJ 2021.1 and 2020.3 and for bothe the most recent version of UnitVisualizer (1.6.1).

The demo-Project (attached zip: UnitVisualizerTest.zip] is just a plain gradle-project (omitting .gradle and .idea) with an added subproject (in settings.gradle). The results of moving classes are seen here:

image

(Before moving World to hello.foo, it had the same symbol-overlay as displayed for foo.bar.blub.HelloWorld still has.)

It would be really great if this could be fixed, as this feature would come in really handy!

Thanks in advance!

Support ClassTests as Test class name

In our project the test class is not called *Test, but *Tests. It would be nice, if these classes were found as well.


I am willing to implement this functionality (by extending the TestClassDetector class) and submit a PR. Please let me know if you're open to include the functionality in your plugin.

Class renaming should cause a Test renaming

It would be a natural enhancement if the plugin supported class renames too. A rename is essentially a file move too. Potentially this feature could be easily implemented with the existing code, if an additional hook/event listener or similar could be set.

How do you feel about it?

StackOverflow error

I'm receiving a stack overflow error. Let me know if I can provide you with more details.

Using latest IDEA (2022.3) and latest plugin version (1.7.3)

java.lang.StackOverflowError
	at com.intellij.openapi.vfs.newvfs.impl.VirtualFileSystemEntry.appendPathOnFileSystem(VirtualFileSystemEntry.java:247)
	at com.intellij.openapi.vfs.newvfs.impl.VirtualFileSystemEntry.appendPathOnFileSystem(VirtualFileSystemEntry.java:247)
	at com.intellij.openapi.vfs.newvfs.impl.VirtualFileSystemEntry.appendPathOnFileSystem(VirtualFileSystemEntry.java:247)
	at com.intellij.openapi.vfs.newvfs.impl.VirtualFileSystemEntry.appendPathOnFileSystem(VirtualFileSystemEntry.java:247)
	at com.intellij.openapi.vfs.newvfs.impl.VirtualFileSystemEntry.appendPathOnFileSystem(VirtualFileSystemEntry.java:247)
	at com.intellij.openapi.vfs.newvfs.impl.VirtualFileSystemEntry.appendPathOnFileSystem(VirtualFileSystemEntry.java:247)
	at com.intellij.openapi.vfs.newvfs.impl.VirtualFileSystemEntry.appendPathOnFileSystem(VirtualFileSystemEntry.java:247)
	at com.intellij.openapi.vfs.newvfs.impl.VirtualFileSystemEntry.appendPathOnFileSystem(VirtualFileSystemEntry.java:247)
	at com.intellij.openapi.vfs.newvfs.impl.VirtualFileSystemEntry.getPath(VirtualFileSystemEntry.java:272)
	at mw.unitv.TestClassMoveHandler.lambda$findTestSourceRootRecursive$2(TestClassMoveHandler.java:174)
	at java.base/java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:178)
	at java.base/java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1625)
	at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:509)
	at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:499)
	at java.base/java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:921)
	at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
	at java.base/java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:682)
	at mw.unitv.TestClassMoveHandler.findTestSourceRootRecursive(TestClassMoveHandler.java:175)
	at mw.unitv.TestClassMoveHandler.findTestSourceRootRecursive(TestClassMoveHandler.java:176)
	at mw.unitv.TestClassMoveHandler.findTestSourceRootRecursive(TestClassMoveHandler.java:176)
	at mw.unitv.TestClassMoveHandler.findTestSourceRootRecursive(TestClassMoveHandler.java:176)
	at mw.unitv.TestClassMoveHandler.findTestSourceRootRecursive(TestClassMoveHandler.java:176)
	at mw.unitv.TestClassMoveHandler.findTestSourceRootRecursive(TestClassMoveHandler.java:176)
	at mw.unitv.TestClassMoveHandler.findTestSourceRootRecursive(TestClassMoveHandler.java:176)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.