> setup; reload

> compile
$ exists target/classes/foo/SealedUsedInPatMatScope.class
$ exists target/classes/foo/SealedNameUsedInDefaultScope.class

# Type of one child of Sealed changed
$ copy-file changed/Sealed1.scala src/main/scala/foo/Sealed.scala
$ touch beforeFirstCompilation
# wait a second to be sure that modifaction date is different on all OSs
$ sleep 1000

> compile
$ exists target/classes/foo/SealedUsedInPatMatScope.class
$ exists target/classes/foo/SealedNameUsedInDefaultScope.class

# Default scopes should not change
$ newer beforeFirstCompilation target/classes/foo/SealedNameUsedInDefaultScope.class
# But PatMat and direct usage of child should be recompiled
$ newer target/classes/foo/SealedUsedInPatMatScope.class beforeFirstCompilation

# Change type of Sealed
$ copy-file changed/Sealed2.scala src/main/scala/foo/Sealed.scala
$ touch beforeSecondCompilation
# wait a second to be sure that modifaction date is different on all OSs
$ sleep 1000

> compile
$ exists target/classes/foo/SealedUsedInPatMatScope.class
$ exists target/classes/foo/SealedNameUsedInDefaultScope.class

# Both PatMat and Default scopes should be recompiled
$ newer target/classes/foo/SealedNameUsedInDefaultScope.class beforeSecondCompilation
$ newer target/classes/foo/SealedUsedInPatMatScope.class beforeSecondCompilation
