diff options
author | Lukas Rytz <lukas.rytz@gmail.com> | 2015-04-01 16:52:54 +0200 |
---|---|---|
committer | Lukas Rytz <lukas.rytz@gmail.com> | 2015-04-01 16:52:54 +0200 |
commit | 3aea9219c40912f1fe501be67e1a630fd595a35d (patch) | |
tree | d6a5634dcaef14f982002fa088df1b5f7ef6b34d /test/junit | |
parent | 51971954ace37ad6af8bf354d92f6baf51d16324 (diff) | |
parent | 32f520f3ed78ecde390dc7b1b48d3130e412a9dc (diff) | |
download | scala-3aea9219c40912f1fe501be67e1a630fd595a35d.tar.gz scala-3aea9219c40912f1fe501be67e1a630fd595a35d.tar.bz2 scala-3aea9219c40912f1fe501be67e1a630fd595a35d.zip |
Merge commit '32f520f' into merge/2.11-to-2.12-apr-1
Diffstat (limited to 'test/junit')
-rw-r--r-- | test/junit/scala/tools/nsc/doc/html/HtmlDocletTest.scala | 22 | ||||
-rw-r--r-- | test/junit/scala/tools/nsc/symtab/SymbolTableTest.scala | 4 |
2 files changed, 24 insertions, 2 deletions
diff --git a/test/junit/scala/tools/nsc/doc/html/HtmlDocletTest.scala b/test/junit/scala/tools/nsc/doc/html/HtmlDocletTest.scala new file mode 100644 index 0000000000..13a955b55d --- /dev/null +++ b/test/junit/scala/tools/nsc/doc/html/HtmlDocletTest.scala @@ -0,0 +1,22 @@ +package scala.tools.nsc.doc.html + +import org.junit.Test +import org.junit.Assert._ +import org.junit.runner.RunWith +import org.junit.runners.JUnit4 + +import scala.tools.testing.AssertUtil._ + +@RunWith(classOf[JUnit4]) +class HtmlDocletTest { + @Test + def testSyntaxHighlightningUnicode() { + val in = "unicode: …" + + val out = SyntaxHigh(in).toString + + // SI-9038, this failed with + // "unicode: …" != "unicode: ¬タᆭ" + assertEquals(in, out) + } +} diff --git a/test/junit/scala/tools/nsc/symtab/SymbolTableTest.scala b/test/junit/scala/tools/nsc/symtab/SymbolTableTest.scala index 895ad9d683..5a921a5eda 100644 --- a/test/junit/scala/tools/nsc/symtab/SymbolTableTest.scala +++ b/test/junit/scala/tools/nsc/symtab/SymbolTableTest.scala @@ -33,10 +33,10 @@ class SymbolTableTest { import symbolTable._ symbolTable.definitions.init() val rootClass = symbolTable.rootMirror.RootClass - val fooSymbol = rootClass.newClassSymbol("Foo": TypeName, NoPosition, 0) + val fooSymbol = rootClass.newClassSymbol(TypeName("Foo"), NoPosition, 0) val fooType = new ClassInfoType(Nil, EmptyScope, fooSymbol) fooSymbol.info = fooType - val barSymbol = rootClass.newClassSymbol("Bar": TypeName, NoPosition, 0) + val barSymbol = rootClass.newClassSymbol(TypeName("Bar"), NoPosition, 0) val fooTypeRef = TypeRef(fooSymbol.owner.tpe, fooSymbol, Nil) val barType = new ClassInfoType(List(fooTypeRef), EmptyScope, barSymbol) barSymbol.info = barType |