Created
January 22, 2013 08:36
-
-
Save spiffxp/4593075 to your computer and use it in GitHub Desktop.
Having an issue getting IntelliJ to highlight ScalaMock 3.x + ScalaTest properly
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.example | |
import org.scalatest.FunSuite | |
import org.scalamock.scalatest.proxy.MockFactory | |
import org.scalamock.scalatest.{MockFactory => RegularMockFactory} | |
import org.scalamock.proxy.ProxyMockFactory | |
trait Highlight | |
class ProxyMockIntelliJHighlightingBrokenTest extends FunSuite with MockFactory { | |
test("unable to resolve mock symbol") { | |
val foo = mock[Highlight] | |
} | |
test("super[ProxyMockFactory] won't compile here") { | |
// val foo = super[ProxyMockFactory].mock[Highlight] | |
} | |
} | |
class ProxyMockIntelliJHighlightingWorkaroundTest extends FunSuite with RegularMockFactory with ProxyMockFactory { | |
test("super[ProxyMockFactory] resolves symbol") { | |
val foo = super[ProxyMockFactory].mock[Highlight] | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment