Junit test in IntelliJ IDE can't see class for testing
intellij-idea, java, junit
Solution
See those white x-es next to the class name?
Somehow you have excluded RandomizedQueue class from the compilation.
Remove it from the excludes and everything will be back to where it was before.
PS: Coursera FTW :-)
Problem
I created simple Java project in IntelliJ, one class (RandomizedQueue) and generated JUnit test class for it. So it's just two files and they both are in the same directory - src. Everything compiled and all was well. For some time. Then suddenly - it stopped with this error: ``` java: cannot find symbol symbol: class RandomizedQueue location: class RandomizedQueueTest ``` I tried everything I could think of. Recreating a project worked for a while but the same error reappeared (without any obvious reason). I can't find any logic in this! Compilation from cmd does work. I tried deleting everything from class and test - and I still can't make an instance in test method. here is the whole project