aboutsummaryrefslogtreecommitdiff
path: root/tests/disabled/scalac-dependent/run/t7775.scala
diff options
context:
space:
mode:
authorGuillaume Martres <smarter@ubuntu.com>2017-02-18 23:13:59 +0100
committerGitHub <noreply@github.com>2017-02-18 23:13:59 +0100
commitf3f1c4623b3815f1385317190bf72baabd98fdff (patch)
tree526aece2cd29373a6a693e6cdd56bdc700f91d02 /tests/disabled/scalac-dependent/run/t7775.scala
parent1946b36ca4abb7ba8264c18af95bc9c9c94f67ee (diff)
parent5aac086d63807331e380bb2d861e4e07800b1f63 (diff)
downloaddotty-f3f1c4623b3815f1385317190bf72baabd98fdff.tar.gz
dotty-f3f1c4623b3815f1385317190bf72baabd98fdff.tar.bz2
dotty-f3f1c4623b3815f1385317190bf72baabd98fdff.zip
Merge pull request #1989 from dotty-staging/remove/scalac-tests
Disable tests that require scala-compiler
Diffstat (limited to 'tests/disabled/scalac-dependent/run/t7775.scala')
-rw-r--r--tests/disabled/scalac-dependent/run/t7775.scala17
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/disabled/scalac-dependent/run/t7775.scala b/tests/disabled/scalac-dependent/run/t7775.scala
new file mode 100644
index 000000000..bc6a67d0e
--- /dev/null
+++ b/tests/disabled/scalac-dependent/run/t7775.scala
@@ -0,0 +1,17 @@
+import scala.concurrent.{duration, Future, Await, ExecutionContext}
+import scala.tools.nsc.Settings
+import ExecutionContext.Implicits.global
+
+// Was failing pretty regularly with a ConcurrentModificationException as
+// WrappedProperties#systemProperties iterated directly over the mutable
+// global system properties map.
+object Test {
+ def main(args: Array[String]): Unit = {
+ val tries = 1000 // YMMV
+ val compiler = Future {
+ for(_ <- 1 to tries) new Settings(_ => {})
+ }
+ for(i <- 1 to tries * 10) System.setProperty(s"foo$i", i.toString)
+ Await.result(compiler, duration.Duration.Inf)
+ }
+}