Merge 'develop' into project-structure
# Conflicts:
# reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/test/GuideReactiveTest.kt
diff --git a/binary-compatibility-validator/build.gradle b/binary-compatibility-validator/build.gradle
index a043287..be32e75 100644
--- a/binary-compatibility-validator/build.gradle
+++ b/binary-compatibility-validator/build.gradle
@@ -37,7 +37,7 @@
sourceSets {
test {
java {
- srcDir "src/test/kotlin"
+ srcDir "test/cases"
}
}
}
diff --git a/binary-compatibility-validator/src/main/kotlin/kotlinx/coroutines/experimental/tools/PublicApiDump.kt b/binary-compatibility-validator/src/PublicApiDump.kt
similarity index 100%
rename from binary-compatibility-validator/src/main/kotlin/kotlinx/coroutines/experimental/tools/PublicApiDump.kt
rename to binary-compatibility-validator/src/PublicApiDump.kt
diff --git a/binary-compatibility-validator/src/main/kotlin/kotlinx/coroutines/experimental/tools/asmUtils.kt b/binary-compatibility-validator/src/asmUtils.kt
similarity index 100%
rename from binary-compatibility-validator/src/main/kotlin/kotlinx/coroutines/experimental/tools/asmUtils.kt
rename to binary-compatibility-validator/src/asmUtils.kt
diff --git a/binary-compatibility-validator/src/main/kotlin/kotlinx/coroutines/experimental/tools/kotlinVisibilities.kt b/binary-compatibility-validator/src/kotlinVisibilities.kt
similarity index 100%
rename from binary-compatibility-validator/src/main/kotlin/kotlinx/coroutines/experimental/tools/kotlinVisibilities.kt
rename to binary-compatibility-validator/src/kotlinVisibilities.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/kotlinx/coroutines/experimental/tools/CasesPublicAPITest.kt b/binary-compatibility-validator/test/CasesPublicAPITest.kt
similarity index 97%
rename from binary-compatibility-validator/src/test/kotlin/kotlinx/coroutines/experimental/tools/CasesPublicAPITest.kt
rename to binary-compatibility-validator/test/CasesPublicAPITest.kt
index 8b23a1f..c1c5266 100644
--- a/binary-compatibility-validator/src/test/kotlin/kotlinx/coroutines/experimental/tools/CasesPublicAPITest.kt
+++ b/binary-compatibility-validator/test/CasesPublicAPITest.kt
@@ -14,7 +14,7 @@
.let { requireNotNull(it) { "Specify testCasesClassesDirs with a system property" } }
.split(File.pathSeparator)
.map { File(it, "cases").canonicalFile }
- val baseOutputPath = File("src/test/kotlin/cases")
+ val baseOutputPath = File("test/cases")
}
@Rule
diff --git a/binary-compatibility-validator/src/test/kotlin/kotlinx/coroutines/experimental/tools/PublicApiTest.kt b/binary-compatibility-validator/test/PublicApiTest.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/kotlinx/coroutines/experimental/tools/PublicApiTest.kt
rename to binary-compatibility-validator/test/PublicApiTest.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/companions/companions.kt b/binary-compatibility-validator/test/cases/companions/companions.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/companions/companions.kt
rename to binary-compatibility-validator/test/cases/companions/companions.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/companions/companions.txt b/binary-compatibility-validator/test/cases/companions/companions.txt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/companions/companions.txt
rename to binary-compatibility-validator/test/cases/companions/companions.txt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/inline/inline.txt b/binary-compatibility-validator/test/cases/inline/inline.txt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/inline/inline.txt
rename to binary-compatibility-validator/test/cases/inline/inline.txt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/inline/inlineExposed.kt b/binary-compatibility-validator/test/cases/inline/inlineExposed.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/inline/inlineExposed.kt
rename to binary-compatibility-validator/test/cases/inline/inlineExposed.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/inline/inlineOnly.kt b/binary-compatibility-validator/test/cases/inline/inlineOnly.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/inline/inlineOnly.kt
rename to binary-compatibility-validator/test/cases/inline/inlineOnly.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/interfaces/interfaceWithEmptyImpls.kt b/binary-compatibility-validator/test/cases/interfaces/interfaceWithEmptyImpls.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/interfaces/interfaceWithEmptyImpls.kt
rename to binary-compatibility-validator/test/cases/interfaces/interfaceWithEmptyImpls.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/interfaces/interfaceWithImpls.kt b/binary-compatibility-validator/test/cases/interfaces/interfaceWithImpls.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/interfaces/interfaceWithImpls.kt
rename to binary-compatibility-validator/test/cases/interfaces/interfaceWithImpls.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/interfaces/interfaces.txt b/binary-compatibility-validator/test/cases/interfaces/interfaces.txt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/interfaces/interfaces.txt
rename to binary-compatibility-validator/test/cases/interfaces/interfaces.txt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/internal/internal.txt b/binary-compatibility-validator/test/cases/internal/internal.txt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/internal/internal.txt
rename to binary-compatibility-validator/test/cases/internal/internal.txt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/internal/internalClass.kt b/binary-compatibility-validator/test/cases/internal/internalClass.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/internal/internalClass.kt
rename to binary-compatibility-validator/test/cases/internal/internalClass.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/internal/internalMultifile1.kt b/binary-compatibility-validator/test/cases/internal/internalMultifile1.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/internal/internalMultifile1.kt
rename to binary-compatibility-validator/test/cases/internal/internalMultifile1.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/internal/internalMultifile2.kt b/binary-compatibility-validator/test/cases/internal/internalMultifile2.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/internal/internalMultifile2.kt
rename to binary-compatibility-validator/test/cases/internal/internalMultifile2.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/internal/internalPart.kt b/binary-compatibility-validator/test/cases/internal/internalPart.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/internal/internalPart.kt
rename to binary-compatibility-validator/test/cases/internal/internalPart.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/internal/publicClassInternalMember.kt b/binary-compatibility-validator/test/cases/internal/publicClassInternalMember.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/internal/publicClassInternalMember.kt
rename to binary-compatibility-validator/test/cases/internal/publicClassInternalMember.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/java/Facade.java b/binary-compatibility-validator/test/cases/java/Facade.java
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/java/Facade.java
rename to binary-compatibility-validator/test/cases/java/Facade.java
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/java/java.txt b/binary-compatibility-validator/test/cases/java/java.txt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/java/java.txt
rename to binary-compatibility-validator/test/cases/java/java.txt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/localClasses/fromStdlib.kt b/binary-compatibility-validator/test/cases/localClasses/fromStdlib.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/localClasses/fromStdlib.kt
rename to binary-compatibility-validator/test/cases/localClasses/fromStdlib.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/localClasses/lambdas.kt b/binary-compatibility-validator/test/cases/localClasses/lambdas.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/localClasses/lambdas.kt
rename to binary-compatibility-validator/test/cases/localClasses/lambdas.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/localClasses/localClasses.kt b/binary-compatibility-validator/test/cases/localClasses/localClasses.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/localClasses/localClasses.kt
rename to binary-compatibility-validator/test/cases/localClasses/localClasses.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/localClasses/localClasses.txt b/binary-compatibility-validator/test/cases/localClasses/localClasses.txt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/localClasses/localClasses.txt
rename to binary-compatibility-validator/test/cases/localClasses/localClasses.txt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/internalClass.kt b/binary-compatibility-validator/test/cases/nestedClasses/internalClass.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/internalClass.kt
rename to binary-compatibility-validator/test/cases/nestedClasses/internalClass.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/internalInterface.kt b/binary-compatibility-validator/test/cases/nestedClasses/internalInterface.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/internalInterface.kt
rename to binary-compatibility-validator/test/cases/nestedClasses/internalInterface.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/internalObject.kt b/binary-compatibility-validator/test/cases/nestedClasses/internalObject.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/internalObject.kt
rename to binary-compatibility-validator/test/cases/nestedClasses/internalObject.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/nestedClasses.txt b/binary-compatibility-validator/test/cases/nestedClasses/nestedClasses.txt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/nestedClasses.txt
rename to binary-compatibility-validator/test/cases/nestedClasses/nestedClasses.txt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/privateClass.kt b/binary-compatibility-validator/test/cases/nestedClasses/privateClass.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/privateClass.kt
rename to binary-compatibility-validator/test/cases/nestedClasses/privateClass.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/privateInterface.kt b/binary-compatibility-validator/test/cases/nestedClasses/privateInterface.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/privateInterface.kt
rename to binary-compatibility-validator/test/cases/nestedClasses/privateInterface.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/privateObject.kt b/binary-compatibility-validator/test/cases/nestedClasses/privateObject.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/privateObject.kt
rename to binary-compatibility-validator/test/cases/nestedClasses/privateObject.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/publicAbstractClass.kt b/binary-compatibility-validator/test/cases/nestedClasses/publicAbstractClass.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/publicAbstractClass.kt
rename to binary-compatibility-validator/test/cases/nestedClasses/publicAbstractClass.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/publicClass.kt b/binary-compatibility-validator/test/cases/nestedClasses/publicClass.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/publicClass.kt
rename to binary-compatibility-validator/test/cases/nestedClasses/publicClass.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/publicInterface.kt b/binary-compatibility-validator/test/cases/nestedClasses/publicInterface.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/publicInterface.kt
rename to binary-compatibility-validator/test/cases/nestedClasses/publicInterface.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/publicObject.kt b/binary-compatibility-validator/test/cases/nestedClasses/publicObject.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/publicObject.kt
rename to binary-compatibility-validator/test/cases/nestedClasses/publicObject.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/publicOpenClass.kt b/binary-compatibility-validator/test/cases/nestedClasses/publicOpenClass.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/nestedClasses/publicOpenClass.kt
rename to binary-compatibility-validator/test/cases/nestedClasses/publicOpenClass.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/private/private.txt b/binary-compatibility-validator/test/cases/private/private.txt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/private/private.txt
rename to binary-compatibility-validator/test/cases/private/private.txt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/private/privateClassMembers.kt b/binary-compatibility-validator/test/cases/private/privateClassMembers.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/private/privateClassMembers.kt
rename to binary-compatibility-validator/test/cases/private/privateClassMembers.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/private/privateMultifile1.kt b/binary-compatibility-validator/test/cases/private/privateMultifile1.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/private/privateMultifile1.kt
rename to binary-compatibility-validator/test/cases/private/privateMultifile1.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/private/privateMultifile2.kt b/binary-compatibility-validator/test/cases/private/privateMultifile2.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/private/privateMultifile2.kt
rename to binary-compatibility-validator/test/cases/private/privateMultifile2.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/private/privatePart.kt b/binary-compatibility-validator/test/cases/private/privatePart.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/private/privatePart.kt
rename to binary-compatibility-validator/test/cases/private/privatePart.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/protected/protected.txt b/binary-compatibility-validator/test/cases/protected/protected.txt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/protected/protected.txt
rename to binary-compatibility-validator/test/cases/protected/protected.txt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/protected/protectedInAbstract.kt b/binary-compatibility-validator/test/cases/protected/protectedInAbstract.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/protected/protectedInAbstract.kt
rename to binary-compatibility-validator/test/cases/protected/protectedInAbstract.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/protected/protectedInFinal.kt b/binary-compatibility-validator/test/cases/protected/protectedInFinal.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/protected/protectedInFinal.kt
rename to binary-compatibility-validator/test/cases/protected/protectedInFinal.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/protected/protectedInOpen.kt b/binary-compatibility-validator/test/cases/protected/protectedInOpen.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/protected/protectedInOpen.kt
rename to binary-compatibility-validator/test/cases/protected/protectedInOpen.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/public/public.txt b/binary-compatibility-validator/test/cases/public/public.txt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/public/public.txt
rename to binary-compatibility-validator/test/cases/public/public.txt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/public/publicMultifile1.kt b/binary-compatibility-validator/test/cases/public/publicMultifile1.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/public/publicMultifile1.kt
rename to binary-compatibility-validator/test/cases/public/publicMultifile1.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/public/publicMultifile2.kt b/binary-compatibility-validator/test/cases/public/publicMultifile2.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/public/publicMultifile2.kt
rename to binary-compatibility-validator/test/cases/public/publicMultifile2.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/public/publicPart.kt b/binary-compatibility-validator/test/cases/public/publicPart.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/public/publicPart.kt
rename to binary-compatibility-validator/test/cases/public/publicPart.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/special/hidden.kt b/binary-compatibility-validator/test/cases/special/hidden.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/special/hidden.kt
rename to binary-compatibility-validator/test/cases/special/hidden.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/special/internalLateinitMember.kt b/binary-compatibility-validator/test/cases/special/internalLateinitMember.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/special/internalLateinitMember.kt
rename to binary-compatibility-validator/test/cases/special/internalLateinitMember.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/special/jvmField.kt b/binary-compatibility-validator/test/cases/special/jvmField.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/special/jvmField.kt
rename to binary-compatibility-validator/test/cases/special/jvmField.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/special/jvmNames.kt b/binary-compatibility-validator/test/cases/special/jvmNames.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/special/jvmNames.kt
rename to binary-compatibility-validator/test/cases/special/jvmNames.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/special/jvmOverloads.kt b/binary-compatibility-validator/test/cases/special/jvmOverloads.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/special/jvmOverloads.kt
rename to binary-compatibility-validator/test/cases/special/jvmOverloads.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/special/special.txt b/binary-compatibility-validator/test/cases/special/special.txt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/special/special.txt
rename to binary-compatibility-validator/test/cases/special/special.txt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/whenMappings/enumWhen.kt b/binary-compatibility-validator/test/cases/whenMappings/enumWhen.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/whenMappings/enumWhen.kt
rename to binary-compatibility-validator/test/cases/whenMappings/enumWhen.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/whenMappings/sealedClassWhen.kt b/binary-compatibility-validator/test/cases/whenMappings/sealedClassWhen.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/whenMappings/sealedClassWhen.kt
rename to binary-compatibility-validator/test/cases/whenMappings/sealedClassWhen.kt
diff --git a/binary-compatibility-validator/src/test/kotlin/cases/whenMappings/whenMappings.txt b/binary-compatibility-validator/test/cases/whenMappings/whenMappings.txt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/cases/whenMappings/whenMappings.txt
rename to binary-compatibility-validator/test/cases/whenMappings/whenMappings.txt
diff --git a/binary-compatibility-validator/src/test/kotlin/kotlinx/coroutines/experimental/tools/utils.kt b/binary-compatibility-validator/test/utils.kt
similarity index 100%
rename from binary-compatibility-validator/src/test/kotlin/kotlinx/coroutines/experimental/tools/utils.kt
rename to binary-compatibility-validator/test/utils.kt
diff --git a/build.gradle b/build.gradle
index 2c37e29..4fe9b51 100644
--- a/build.gradle
+++ b/build.gradle
@@ -95,6 +95,14 @@
def internal = sourceless + ['benchmarks', 'knit', 'js-stub', 'binary-compatibility-validator']
+// Reconfigure source sets to avoid long "src/main/kotlin/fqn"
+configure(subprojects.findAll { !it.name.contains(sourceless) && it.name != "benchmarks" }) {
+ sourceSets {
+ main.kotlin.srcDirs = ["src/"]
+ test.kotlin.srcDirs = ["test/"]
+ }
+}
+
// configure atomicfu
configure(subprojects.findAll { !internal.contains(it.name) }) {
def platform = platformOf(it)
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/AbstractContinuation.kt b/common/kotlinx-coroutines-core-common/src/AbstractContinuation.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/AbstractContinuation.kt
rename to common/kotlinx-coroutines-core-common/src/AbstractContinuation.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/AbstractCoroutine.kt b/common/kotlinx-coroutines-core-common/src/AbstractCoroutine.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/AbstractCoroutine.kt
rename to common/kotlinx-coroutines-core-common/src/AbstractCoroutine.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Annotations.common.kt b/common/kotlinx-coroutines-core-common/src/Annotations.common.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Annotations.common.kt
rename to common/kotlinx-coroutines-core-common/src/Annotations.common.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Await.kt b/common/kotlinx-coroutines-core-common/src/Await.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Await.kt
rename to common/kotlinx-coroutines-core-common/src/Await.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Builders.common.kt b/common/kotlinx-coroutines-core-common/src/Builders.common.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Builders.common.kt
rename to common/kotlinx-coroutines-core-common/src/Builders.common.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/CancellableContinuation.kt b/common/kotlinx-coroutines-core-common/src/CancellableContinuation.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/CancellableContinuation.kt
rename to common/kotlinx-coroutines-core-common/src/CancellableContinuation.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/CompletableDeferred.kt b/common/kotlinx-coroutines-core-common/src/CompletableDeferred.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/CompletableDeferred.kt
rename to common/kotlinx-coroutines-core-common/src/CompletableDeferred.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/CompletedExceptionally.kt b/common/kotlinx-coroutines-core-common/src/CompletedExceptionally.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/CompletedExceptionally.kt
rename to common/kotlinx-coroutines-core-common/src/CompletedExceptionally.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/CompletionHandler.common.kt b/common/kotlinx-coroutines-core-common/src/CompletionHandler.common.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/CompletionHandler.common.kt
rename to common/kotlinx-coroutines-core-common/src/CompletionHandler.common.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/CoroutineContext.common.kt b/common/kotlinx-coroutines-core-common/src/CoroutineContext.common.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/CoroutineContext.common.kt
rename to common/kotlinx-coroutines-core-common/src/CoroutineContext.common.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/CoroutineDispatcher.kt b/common/kotlinx-coroutines-core-common/src/CoroutineDispatcher.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/CoroutineDispatcher.kt
rename to common/kotlinx-coroutines-core-common/src/CoroutineDispatcher.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/CoroutineExceptionHandler.kt b/common/kotlinx-coroutines-core-common/src/CoroutineExceptionHandler.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/CoroutineExceptionHandler.kt
rename to common/kotlinx-coroutines-core-common/src/CoroutineExceptionHandler.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/CoroutineScope.kt b/common/kotlinx-coroutines-core-common/src/CoroutineScope.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/CoroutineScope.kt
rename to common/kotlinx-coroutines-core-common/src/CoroutineScope.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/CoroutineStart.kt b/common/kotlinx-coroutines-core-common/src/CoroutineStart.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/CoroutineStart.kt
rename to common/kotlinx-coroutines-core-common/src/CoroutineStart.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Debug.common.kt b/common/kotlinx-coroutines-core-common/src/Debug.common.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Debug.common.kt
rename to common/kotlinx-coroutines-core-common/src/Debug.common.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Deferred.kt b/common/kotlinx-coroutines-core-common/src/Deferred.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Deferred.kt
rename to common/kotlinx-coroutines-core-common/src/Deferred.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Delay.kt b/common/kotlinx-coroutines-core-common/src/Delay.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Delay.kt
rename to common/kotlinx-coroutines-core-common/src/Delay.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Dispatched.kt b/common/kotlinx-coroutines-core-common/src/Dispatched.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Dispatched.kt
rename to common/kotlinx-coroutines-core-common/src/Dispatched.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Exceptions.common.kt b/common/kotlinx-coroutines-core-common/src/Exceptions.common.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Exceptions.common.kt
rename to common/kotlinx-coroutines-core-common/src/Exceptions.common.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Job.kt b/common/kotlinx-coroutines-core-common/src/Job.kt
similarity index 97%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Job.kt
rename to common/kotlinx-coroutines-core-common/src/Job.kt
index 3fcfc49..49627ab 100644
--- a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Job.kt
+++ b/common/kotlinx-coroutines-core-common/src/Job.kt
@@ -1,17 +1,6 @@
/*
- * Copyright 2016-2017 JetBrains s.r.o.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
+ * Copyright 2010-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license
+ * that can be found in the license/LICENSE.txt file.
*/
@file:JvmMultifileClass
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/JobSupport.kt b/common/kotlinx-coroutines-core-common/src/JobSupport.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/JobSupport.kt
rename to common/kotlinx-coroutines-core-common/src/JobSupport.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/NonCancellable.kt b/common/kotlinx-coroutines-core-common/src/NonCancellable.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/NonCancellable.kt
rename to common/kotlinx-coroutines-core-common/src/NonCancellable.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/ResumeMode.kt b/common/kotlinx-coroutines-core-common/src/ResumeMode.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/ResumeMode.kt
rename to common/kotlinx-coroutines-core-common/src/ResumeMode.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Runnable.common.kt b/common/kotlinx-coroutines-core-common/src/Runnable.common.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Runnable.common.kt
rename to common/kotlinx-coroutines-core-common/src/Runnable.common.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Scheduled.kt b/common/kotlinx-coroutines-core-common/src/Scheduled.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Scheduled.kt
rename to common/kotlinx-coroutines-core-common/src/Scheduled.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Unconfined.kt b/common/kotlinx-coroutines-core-common/src/Unconfined.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Unconfined.kt
rename to common/kotlinx-coroutines-core-common/src/Unconfined.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Yield.kt b/common/kotlinx-coroutines-core-common/src/Yield.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/Yield.kt
rename to common/kotlinx-coroutines-core-common/src/Yield.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/AbstractChannel.kt b/common/kotlinx-coroutines-core-common/src/channels/AbstractChannel.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/AbstractChannel.kt
rename to common/kotlinx-coroutines-core-common/src/channels/AbstractChannel.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/ArrayBroadcastChannel.kt b/common/kotlinx-coroutines-core-common/src/channels/ArrayBroadcastChannel.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/ArrayBroadcastChannel.kt
rename to common/kotlinx-coroutines-core-common/src/channels/ArrayBroadcastChannel.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/ArrayChannel.kt b/common/kotlinx-coroutines-core-common/src/channels/ArrayChannel.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/ArrayChannel.kt
rename to common/kotlinx-coroutines-core-common/src/channels/ArrayChannel.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/Broadcast.kt b/common/kotlinx-coroutines-core-common/src/channels/Broadcast.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/Broadcast.kt
rename to common/kotlinx-coroutines-core-common/src/channels/Broadcast.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/BroadcastChannel.kt b/common/kotlinx-coroutines-core-common/src/channels/BroadcastChannel.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/BroadcastChannel.kt
rename to common/kotlinx-coroutines-core-common/src/channels/BroadcastChannel.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/Channel.kt b/common/kotlinx-coroutines-core-common/src/channels/Channel.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/Channel.kt
rename to common/kotlinx-coroutines-core-common/src/channels/Channel.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/ChannelCoroutine.kt b/common/kotlinx-coroutines-core-common/src/channels/ChannelCoroutine.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/ChannelCoroutine.kt
rename to common/kotlinx-coroutines-core-common/src/channels/ChannelCoroutine.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/Channels.common.kt b/common/kotlinx-coroutines-core-common/src/channels/Channels.common.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/Channels.common.kt
rename to common/kotlinx-coroutines-core-common/src/channels/Channels.common.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/ConflatedBroadcastChannel.kt b/common/kotlinx-coroutines-core-common/src/channels/ConflatedBroadcastChannel.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/ConflatedBroadcastChannel.kt
rename to common/kotlinx-coroutines-core-common/src/channels/ConflatedBroadcastChannel.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/ConflatedChannel.kt b/common/kotlinx-coroutines-core-common/src/channels/ConflatedChannel.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/ConflatedChannel.kt
rename to common/kotlinx-coroutines-core-common/src/channels/ConflatedChannel.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/LinkedListChannel.kt b/common/kotlinx-coroutines-core-common/src/channels/LinkedListChannel.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/LinkedListChannel.kt
rename to common/kotlinx-coroutines-core-common/src/channels/LinkedListChannel.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/Produce.kt b/common/kotlinx-coroutines-core-common/src/channels/Produce.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/Produce.kt
rename to common/kotlinx-coroutines-core-common/src/channels/Produce.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/RendezvousChannel.kt b/common/kotlinx-coroutines-core-common/src/channels/RendezvousChannel.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/channels/RendezvousChannel.kt
rename to common/kotlinx-coroutines-core-common/src/channels/RendezvousChannel.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/internal/ArrayCopy.common.kt b/common/kotlinx-coroutines-core-common/src/internal/ArrayCopy.common.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/internal/ArrayCopy.common.kt
rename to common/kotlinx-coroutines-core-common/src/internal/ArrayCopy.common.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/internal/Atomic.kt b/common/kotlinx-coroutines-core-common/src/internal/Atomic.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/internal/Atomic.kt
rename to common/kotlinx-coroutines-core-common/src/internal/Atomic.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/internal/Closeable.common.kt b/common/kotlinx-coroutines-core-common/src/internal/Closeable.common.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/internal/Closeable.common.kt
rename to common/kotlinx-coroutines-core-common/src/internal/Closeable.common.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/internal/Concurrent.common.kt b/common/kotlinx-coroutines-core-common/src/internal/Concurrent.common.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/internal/Concurrent.common.kt
rename to common/kotlinx-coroutines-core-common/src/internal/Concurrent.common.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/internal/LockFreeLinkedList.common.kt b/common/kotlinx-coroutines-core-common/src/internal/LockFreeLinkedList.common.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/internal/LockFreeLinkedList.common.kt
rename to common/kotlinx-coroutines-core-common/src/internal/LockFreeLinkedList.common.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/internal/Symbol.kt b/common/kotlinx-coroutines-core-common/src/internal/Symbol.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/internal/Symbol.kt
rename to common/kotlinx-coroutines-core-common/src/internal/Symbol.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/intrinsics/Cancellable.kt b/common/kotlinx-coroutines-core-common/src/intrinsics/Cancellable.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/intrinsics/Cancellable.kt
rename to common/kotlinx-coroutines-core-common/src/intrinsics/Cancellable.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/intrinsics/Undispatched.kt b/common/kotlinx-coroutines-core-common/src/intrinsics/Undispatched.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/intrinsics/Undispatched.kt
rename to common/kotlinx-coroutines-core-common/src/intrinsics/Undispatched.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/selects/Select.kt b/common/kotlinx-coroutines-core-common/src/selects/Select.kt
similarity index 99%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/selects/Select.kt
rename to common/kotlinx-coroutines-core-common/src/selects/Select.kt
index 44a0e83..3c01430 100644
--- a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/selects/Select.kt
+++ b/common/kotlinx-coroutines-core-common/src/selects/Select.kt
@@ -181,6 +181,7 @@
* Use [yield] or [CoroutineScope.isActive] to periodically check for cancellation in tight loops if needed.
*/
public suspend inline fun <R> select(crossinline builder: SelectBuilder<R>.() -> Unit): R =
+ // TODO suspendCoroutineUnintercepted
suspendCoroutineOrReturn { cont ->
val scope = SelectBuilderImpl(cont)
try {
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/selects/SelectUnbiased.kt b/common/kotlinx-coroutines-core-common/src/selects/SelectUnbiased.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/selects/SelectUnbiased.kt
rename to common/kotlinx-coroutines-core-common/src/selects/SelectUnbiased.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/selects/WhileSelect.kt b/common/kotlinx-coroutines-core-common/src/selects/WhileSelect.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/selects/WhileSelect.kt
rename to common/kotlinx-coroutines-core-common/src/selects/WhileSelect.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/sync/Mutex.kt b/common/kotlinx-coroutines-core-common/src/sync/Mutex.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/sync/Mutex.kt
rename to common/kotlinx-coroutines-core-common/src/sync/Mutex.kt
diff --git a/common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/timeunit/TimeUnit.common.kt b/common/kotlinx-coroutines-core-common/src/timeunit/TimeUnit.common.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/main/kotlin/kotlinx/coroutines/experimental/timeunit/TimeUnit.common.kt
rename to common/kotlinx-coroutines-core-common/src/timeunit/TimeUnit.common.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/AbstractCoroutineTest.kt b/common/kotlinx-coroutines-core-common/test/AbstractCoroutineTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/AbstractCoroutineTest.kt
rename to common/kotlinx-coroutines-core-common/test/AbstractCoroutineTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/AsyncLazyTest.kt b/common/kotlinx-coroutines-core-common/test/AsyncLazyTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/AsyncLazyTest.kt
rename to common/kotlinx-coroutines-core-common/test/AsyncLazyTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/AsyncTest.kt b/common/kotlinx-coroutines-core-common/test/AsyncTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/AsyncTest.kt
rename to common/kotlinx-coroutines-core-common/test/AsyncTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/AtomicCancellationCommonTest.kt b/common/kotlinx-coroutines-core-common/test/AtomicCancellationCommonTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/AtomicCancellationCommonTest.kt
rename to common/kotlinx-coroutines-core-common/test/AtomicCancellationCommonTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/AwaitTest.kt b/common/kotlinx-coroutines-core-common/test/AwaitTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/AwaitTest.kt
rename to common/kotlinx-coroutines-core-common/test/AwaitTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/CancellableContinuationHandlersTest.kt b/common/kotlinx-coroutines-core-common/test/CancellableContinuationHandlersTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/CancellableContinuationHandlersTest.kt
rename to common/kotlinx-coroutines-core-common/test/CancellableContinuationHandlersTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/CompletableDeferredTest.kt b/common/kotlinx-coroutines-core-common/test/CompletableDeferredTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/CompletableDeferredTest.kt
rename to common/kotlinx-coroutines-core-common/test/CompletableDeferredTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/CoroutineExceptionHandlerTest.kt b/common/kotlinx-coroutines-core-common/test/CoroutineExceptionHandlerTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/CoroutineExceptionHandlerTest.kt
rename to common/kotlinx-coroutines-core-common/test/CoroutineExceptionHandlerTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/CoroutinesTest.kt b/common/kotlinx-coroutines-core-common/test/CoroutinesTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/CoroutinesTest.kt
rename to common/kotlinx-coroutines-core-common/test/CoroutinesTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/DelayTest.kt b/common/kotlinx-coroutines-core-common/test/DelayTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/DelayTest.kt
rename to common/kotlinx-coroutines-core-common/test/DelayTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/JobTest.kt b/common/kotlinx-coroutines-core-common/test/JobTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/JobTest.kt
rename to common/kotlinx-coroutines-core-common/test/JobTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/LaunchLazyTest.kt b/common/kotlinx-coroutines-core-common/test/LaunchLazyTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/LaunchLazyTest.kt
rename to common/kotlinx-coroutines-core-common/test/LaunchLazyTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/NonCancellableTest.kt b/common/kotlinx-coroutines-core-common/test/NonCancellableTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/NonCancellableTest.kt
rename to common/kotlinx-coroutines-core-common/test/NonCancellableTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/TestBase.common.kt b/common/kotlinx-coroutines-core-common/test/TestBase.common.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/TestBase.common.kt
rename to common/kotlinx-coroutines-core-common/test/TestBase.common.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/Try.kt b/common/kotlinx-coroutines-core-common/test/Try.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/Try.kt
rename to common/kotlinx-coroutines-core-common/test/Try.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/WithContextTest.kt b/common/kotlinx-coroutines-core-common/test/WithContextTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/WithContextTest.kt
rename to common/kotlinx-coroutines-core-common/test/WithContextTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/WithTimeoutOrNullTest.kt b/common/kotlinx-coroutines-core-common/test/WithTimeoutOrNullTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/WithTimeoutOrNullTest.kt
rename to common/kotlinx-coroutines-core-common/test/WithTimeoutOrNullTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/WithTimeoutTest.kt b/common/kotlinx-coroutines-core-common/test/WithTimeoutTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/WithTimeoutTest.kt
rename to common/kotlinx-coroutines-core-common/test/WithTimeoutTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/ArrayBroadcastChannelTest.kt b/common/kotlinx-coroutines-core-common/test/channels/ArrayBroadcastChannelTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/ArrayBroadcastChannelTest.kt
rename to common/kotlinx-coroutines-core-common/test/channels/ArrayBroadcastChannelTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/ArrayChannelTest.kt b/common/kotlinx-coroutines-core-common/test/channels/ArrayChannelTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/ArrayChannelTest.kt
rename to common/kotlinx-coroutines-core-common/test/channels/ArrayChannelTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/BroadcastChannelFactoryTest.kt b/common/kotlinx-coroutines-core-common/test/channels/BroadcastChannelFactoryTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/BroadcastChannelFactoryTest.kt
rename to common/kotlinx-coroutines-core-common/test/channels/BroadcastChannelFactoryTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/BroadcastTest.kt b/common/kotlinx-coroutines-core-common/test/channels/BroadcastTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/BroadcastTest.kt
rename to common/kotlinx-coroutines-core-common/test/channels/BroadcastTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/ChannelFactoryTest.kt b/common/kotlinx-coroutines-core-common/test/channels/ChannelFactoryTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/ChannelFactoryTest.kt
rename to common/kotlinx-coroutines-core-common/test/channels/ChannelFactoryTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/ChannelsTest.kt b/common/kotlinx-coroutines-core-common/test/channels/ChannelsTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/ChannelsTest.kt
rename to common/kotlinx-coroutines-core-common/test/channels/ChannelsTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/ConflatedBroadcastChannelTest.kt b/common/kotlinx-coroutines-core-common/test/channels/ConflatedBroadcastChannelTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/ConflatedBroadcastChannelTest.kt
rename to common/kotlinx-coroutines-core-common/test/channels/ConflatedBroadcastChannelTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/ConflatedChannelTest.kt b/common/kotlinx-coroutines-core-common/test/channels/ConflatedChannelTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/ConflatedChannelTest.kt
rename to common/kotlinx-coroutines-core-common/test/channels/ConflatedChannelTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/LinkedListChannelTest.kt b/common/kotlinx-coroutines-core-common/test/channels/LinkedListChannelTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/LinkedListChannelTest.kt
rename to common/kotlinx-coroutines-core-common/test/channels/LinkedListChannelTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/ProduceConsumeTest.kt b/common/kotlinx-coroutines-core-common/test/channels/ProduceConsumeTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/ProduceConsumeTest.kt
rename to common/kotlinx-coroutines-core-common/test/channels/ProduceConsumeTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/ProduceTest.kt b/common/kotlinx-coroutines-core-common/test/channels/ProduceTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/ProduceTest.kt
rename to common/kotlinx-coroutines-core-common/test/channels/ProduceTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/RendezvousChannelTest.kt b/common/kotlinx-coroutines-core-common/test/channels/RendezvousChannelTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/RendezvousChannelTest.kt
rename to common/kotlinx-coroutines-core-common/test/channels/RendezvousChannelTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/SendReceiveStressTest.kt b/common/kotlinx-coroutines-core-common/test/channels/SendReceiveStressTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/SendReceiveStressTest.kt
rename to common/kotlinx-coroutines-core-common/test/channels/SendReceiveStressTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/SimpleSendReceiveTest.kt b/common/kotlinx-coroutines-core-common/test/channels/SimpleSendReceiveTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/SimpleSendReceiveTest.kt
rename to common/kotlinx-coroutines-core-common/test/channels/SimpleSendReceiveTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/TestBroadcastChannelKind.kt b/common/kotlinx-coroutines-core-common/test/channels/TestBroadcastChannelKind.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/TestBroadcastChannelKind.kt
rename to common/kotlinx-coroutines-core-common/test/channels/TestBroadcastChannelKind.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/TestChannelKind.kt b/common/kotlinx-coroutines-core-common/test/channels/TestChannelKind.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/channels/TestChannelKind.kt
rename to common/kotlinx-coroutines-core-common/test/channels/TestChannelKind.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectArrayChannelTest.kt b/common/kotlinx-coroutines-core-common/test/selects/SelectArrayChannelTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectArrayChannelTest.kt
rename to common/kotlinx-coroutines-core-common/test/selects/SelectArrayChannelTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectBiasTest.kt b/common/kotlinx-coroutines-core-common/test/selects/SelectBiasTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectBiasTest.kt
rename to common/kotlinx-coroutines-core-common/test/selects/SelectBiasTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectBuilderImplTest.kt b/common/kotlinx-coroutines-core-common/test/selects/SelectBuilderImplTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectBuilderImplTest.kt
rename to common/kotlinx-coroutines-core-common/test/selects/SelectBuilderImplTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectDeferredTest.kt b/common/kotlinx-coroutines-core-common/test/selects/SelectDeferredTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectDeferredTest.kt
rename to common/kotlinx-coroutines-core-common/test/selects/SelectDeferredTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectJobTest.kt b/common/kotlinx-coroutines-core-common/test/selects/SelectJobTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectJobTest.kt
rename to common/kotlinx-coroutines-core-common/test/selects/SelectJobTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectMutexTest.kt b/common/kotlinx-coroutines-core-common/test/selects/SelectMutexTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectMutexTest.kt
rename to common/kotlinx-coroutines-core-common/test/selects/SelectMutexTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectRendezvousChannelTest.kt b/common/kotlinx-coroutines-core-common/test/selects/SelectRendezvousChannelTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectRendezvousChannelTest.kt
rename to common/kotlinx-coroutines-core-common/test/selects/SelectRendezvousChannelTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectTimeoutTest.kt b/common/kotlinx-coroutines-core-common/test/selects/SelectTimeoutTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectTimeoutTest.kt
rename to common/kotlinx-coroutines-core-common/test/selects/SelectTimeoutTest.kt
diff --git a/common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/sync/MutexTest.kt b/common/kotlinx-coroutines-core-common/test/sync/MutexTest.kt
similarity index 100%
rename from common/kotlinx-coroutines-core-common/src/test/kotlin/kotlinx/coroutines/experimental/sync/MutexTest.kt
rename to common/kotlinx-coroutines-core-common/test/sync/MutexTest.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/Annotations.kt b/core/kotlinx-coroutines-core/src/Annotations.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/Annotations.kt
rename to core/kotlinx-coroutines-core/src/Annotations.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/Builders.kt b/core/kotlinx-coroutines-core/src/Builders.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/Builders.kt
rename to core/kotlinx-coroutines-core/src/Builders.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/CommonPool.kt b/core/kotlinx-coroutines-core/src/CommonPool.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/CommonPool.kt
rename to core/kotlinx-coroutines-core/src/CommonPool.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/CompletionHandler.kt b/core/kotlinx-coroutines-core/src/CompletionHandler.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/CompletionHandler.kt
rename to core/kotlinx-coroutines-core/src/CompletionHandler.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/CoroutineContext.kt b/core/kotlinx-coroutines-core/src/CoroutineContext.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/CoroutineContext.kt
rename to core/kotlinx-coroutines-core/src/CoroutineContext.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/CoroutineExceptionHandlerImpl.kt b/core/kotlinx-coroutines-core/src/CoroutineExceptionHandlerImpl.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/CoroutineExceptionHandlerImpl.kt
rename to core/kotlinx-coroutines-core/src/CoroutineExceptionHandlerImpl.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/CoroutineName.kt b/core/kotlinx-coroutines-core/src/CoroutineName.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/CoroutineName.kt
rename to core/kotlinx-coroutines-core/src/CoroutineName.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/Debug.kt b/core/kotlinx-coroutines-core/src/Debug.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/Debug.kt
rename to core/kotlinx-coroutines-core/src/Debug.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/DefaultExecutor.kt b/core/kotlinx-coroutines-core/src/DefaultExecutor.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/DefaultExecutor.kt
rename to core/kotlinx-coroutines-core/src/DefaultExecutor.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/EventLoop.kt b/core/kotlinx-coroutines-core/src/EventLoop.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/EventLoop.kt
rename to core/kotlinx-coroutines-core/src/EventLoop.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/Exceptions.kt b/core/kotlinx-coroutines-core/src/Exceptions.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/Exceptions.kt
rename to core/kotlinx-coroutines-core/src/Exceptions.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/Executors.kt b/core/kotlinx-coroutines-core/src/Executors.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/Executors.kt
rename to core/kotlinx-coroutines-core/src/Executors.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/Future.kt b/core/kotlinx-coroutines-core/src/Future.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/Future.kt
rename to core/kotlinx-coroutines-core/src/Future.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/LazyDeferred.kt b/core/kotlinx-coroutines-core/src/LazyDeferred.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/LazyDeferred.kt
rename to core/kotlinx-coroutines-core/src/LazyDeferred.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/Runnable.kt b/core/kotlinx-coroutines-core/src/Runnable.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/Runnable.kt
rename to core/kotlinx-coroutines-core/src/Runnable.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/ThreadPoolDispatcher.kt b/core/kotlinx-coroutines-core/src/ThreadPoolDispatcher.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/ThreadPoolDispatcher.kt
rename to core/kotlinx-coroutines-core/src/ThreadPoolDispatcher.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/TimeSource.kt b/core/kotlinx-coroutines-core/src/TimeSource.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/TimeSource.kt
rename to core/kotlinx-coroutines-core/src/TimeSource.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/channels/Actor.kt b/core/kotlinx-coroutines-core/src/channels/Actor.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/channels/Actor.kt
rename to core/kotlinx-coroutines-core/src/channels/Actor.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/channels/Channels.kt b/core/kotlinx-coroutines-core/src/channels/Channels.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/channels/Channels.kt
rename to core/kotlinx-coroutines-core/src/channels/Channels.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/channels/TickerChannels.kt b/core/kotlinx-coroutines-core/src/channels/TickerChannels.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/channels/TickerChannels.kt
rename to core/kotlinx-coroutines-core/src/channels/TickerChannels.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/internal/ArrayCopy.kt b/core/kotlinx-coroutines-core/src/internal/ArrayCopy.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/internal/ArrayCopy.kt
rename to core/kotlinx-coroutines-core/src/internal/ArrayCopy.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/internal/Closeable.kt b/core/kotlinx-coroutines-core/src/internal/Closeable.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/internal/Closeable.kt
rename to core/kotlinx-coroutines-core/src/internal/Closeable.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/internal/Concurrent.kt b/core/kotlinx-coroutines-core/src/internal/Concurrent.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/internal/Concurrent.kt
rename to core/kotlinx-coroutines-core/src/internal/Concurrent.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/internal/LockFreeLinkedList.kt b/core/kotlinx-coroutines-core/src/internal/LockFreeLinkedList.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/internal/LockFreeLinkedList.kt
rename to core/kotlinx-coroutines-core/src/internal/LockFreeLinkedList.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/internal/LockFreeMPSCQueue.kt b/core/kotlinx-coroutines-core/src/internal/LockFreeMPSCQueue.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/internal/LockFreeMPSCQueue.kt
rename to core/kotlinx-coroutines-core/src/internal/LockFreeMPSCQueue.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/internal/ThreadSafeHeap.kt b/core/kotlinx-coroutines-core/src/internal/ThreadSafeHeap.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/internal/ThreadSafeHeap.kt
rename to core/kotlinx-coroutines-core/src/internal/ThreadSafeHeap.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/test/GuideTest.kt b/core/kotlinx-coroutines-core/src/test/kotlin/guide/test/GuideTest.kt
deleted file mode 100644
index 81cf2a2..0000000
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/test/GuideTest.kt
+++ /dev/null
@@ -1,511 +0,0 @@
-// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.test
-
-import org.junit.Test
-
-class GuideTest {
-
- @Test
- fun testGuideBasicExample01() {
- test("GuideBasicExample01") { guide.basic.example01.main(emptyArray()) }.verifyLines(
- "Hello,",
- "World!"
- )
- }
-
- @Test
- fun testGuideBasicExample02() {
- test("GuideBasicExample02") { guide.basic.example02.main(emptyArray()) }.verifyLines(
- "Hello,",
- "World!"
- )
- }
-
- @Test
- fun testGuideBasicExample02b() {
- test("GuideBasicExample02b") { guide.basic.example02b.main(emptyArray()) }.verifyLines(
- "Hello,",
- "World!"
- )
- }
-
- @Test
- fun testGuideBasicExample03() {
- test("GuideBasicExample03") { guide.basic.example03.main(emptyArray()) }.verifyLines(
- "Hello,",
- "World!"
- )
- }
-
- @Test
- fun testGuideBasicExample04() {
- test("GuideBasicExample04") { guide.basic.example04.main(emptyArray()) }.verifyLines(
- "Hello,",
- "World!"
- )
- }
-
- @Test
- fun testGuideBasicExample05() {
- test("GuideBasicExample05") { guide.basic.example05.main(emptyArray()) }.also { lines ->
- check(lines.size == 1 && lines[0] == ".".repeat(100_000))
- }
- }
-
- @Test
- fun testGuideBasicExample06() {
- test("GuideBasicExample06") { guide.basic.example06.main(emptyArray()) }.verifyLines(
- "I'm sleeping 0 ...",
- "I'm sleeping 1 ...",
- "I'm sleeping 2 ..."
- )
- }
-
- @Test
- fun testGuideCancelExample01() {
- test("GuideCancelExample01") { guide.cancel.example01.main(emptyArray()) }.verifyLines(
- "I'm sleeping 0 ...",
- "I'm sleeping 1 ...",
- "I'm sleeping 2 ...",
- "main: I'm tired of waiting!",
- "main: Now I can quit."
- )
- }
-
- @Test
- fun testGuideCancelExample02() {
- test("GuideCancelExample02") { guide.cancel.example02.main(emptyArray()) }.verifyLines(
- "I'm sleeping 0 ...",
- "I'm sleeping 1 ...",
- "I'm sleeping 2 ...",
- "main: I'm tired of waiting!",
- "I'm sleeping 3 ...",
- "I'm sleeping 4 ...",
- "main: Now I can quit."
- )
- }
-
- @Test
- fun testGuideCancelExample03() {
- test("GuideCancelExample03") { guide.cancel.example03.main(emptyArray()) }.verifyLines(
- "I'm sleeping 0 ...",
- "I'm sleeping 1 ...",
- "I'm sleeping 2 ...",
- "main: I'm tired of waiting!",
- "main: Now I can quit."
- )
- }
-
- @Test
- fun testGuideCancelExample04() {
- test("GuideCancelExample04") { guide.cancel.example04.main(emptyArray()) }.verifyLines(
- "I'm sleeping 0 ...",
- "I'm sleeping 1 ...",
- "I'm sleeping 2 ...",
- "main: I'm tired of waiting!",
- "I'm running finally",
- "main: Now I can quit."
- )
- }
-
- @Test
- fun testGuideCancelExample05() {
- test("GuideCancelExample05") { guide.cancel.example05.main(emptyArray()) }.verifyLines(
- "I'm sleeping 0 ...",
- "I'm sleeping 1 ...",
- "I'm sleeping 2 ...",
- "main: I'm tired of waiting!",
- "I'm running finally",
- "And I've just delayed for 1 sec because I'm non-cancellable",
- "main: Now I can quit."
- )
- }
-
- @Test
- fun testGuideCancelExample06() {
- test("GuideCancelExample06") { guide.cancel.example06.main(emptyArray()) }.verifyLinesStartWith(
- "I'm sleeping 0 ...",
- "I'm sleeping 1 ...",
- "I'm sleeping 2 ...",
- "Exception in thread \"main\" kotlinx.coroutines.experimental.TimeoutCancellationException: Timed out waiting for 1300 MILLISECONDS"
- )
- }
-
- @Test
- fun testGuideCancelExample07() {
- test("GuideCancelExample07") { guide.cancel.example07.main(emptyArray()) }.verifyLines(
- "I'm sleeping 0 ...",
- "I'm sleeping 1 ...",
- "I'm sleeping 2 ...",
- "Result is null"
- )
- }
-
- @Test
- fun testGuideComposeExample01() {
- test("GuideComposeExample01") { guide.compose.example01.main(emptyArray()) }.verifyLinesArbitraryTime(
- "The answer is 42",
- "Completed in 2017 ms"
- )
- }
-
- @Test
- fun testGuideComposeExample02() {
- test("GuideComposeExample02") { guide.compose.example02.main(emptyArray()) }.verifyLinesArbitraryTime(
- "The answer is 42",
- "Completed in 1017 ms"
- )
- }
-
- @Test
- fun testGuideComposeExample03() {
- test("GuideComposeExample03") { guide.compose.example03.main(emptyArray()) }.verifyLinesArbitraryTime(
- "The answer is 42",
- "Completed in 2017 ms"
- )
- }
-
- @Test
- fun testGuideComposeExample04() {
- test("GuideComposeExample04") { guide.compose.example04.main(emptyArray()) }.verifyLinesArbitraryTime(
- "The answer is 42",
- "Completed in 1085 ms"
- )
- }
-
- @Test
- fun testGuideContextExample01() {
- test("GuideContextExample01") { guide.context.example01.main(emptyArray()) }.verifyLinesStartUnordered(
- " 'Unconfined': I'm working in thread main",
- " 'CommonPool': I'm working in thread ForkJoinPool.commonPool-worker-1",
- " 'newSTC': I'm working in thread MyOwnThread",
- "'coroutineContext': I'm working in thread main"
- )
- }
-
- @Test
- fun testGuideContextExample02() {
- test("GuideContextExample02") { guide.context.example02.main(emptyArray()) }.verifyLinesStart(
- " 'Unconfined': I'm working in thread main",
- "'coroutineContext': I'm working in thread main",
- " 'Unconfined': After delay in thread kotlinx.coroutines.DefaultExecutor",
- "'coroutineContext': After delay in thread main"
- )
- }
-
- @Test
- fun testGuideContextExample03() {
- test("GuideContextExample03") { guide.context.example03.main(emptyArray()) }.verifyLinesFlexibleThread(
- "[main @coroutine#2] I'm computing a piece of the answer",
- "[main @coroutine#3] I'm computing another piece of the answer",
- "[main @coroutine#1] The answer is 42"
- )
- }
-
- @Test
- fun testGuideContextExample04() {
- test("GuideContextExample04") { guide.context.example04.main(emptyArray()) }.verifyLines(
- "[Ctx1 @coroutine#1] Started in ctx1",
- "[Ctx2 @coroutine#1] Working in ctx2",
- "[Ctx1 @coroutine#1] Back to ctx1"
- )
- }
-
- @Test
- fun testGuideContextExample05() {
- test("GuideContextExample05") { guide.context.example05.main(emptyArray()) }.also { lines ->
- check(lines.size == 1 && lines[0].startsWith("My job is \"coroutine#1\":BlockingCoroutine{Active}@"))
- }
- }
-
- @Test
- fun testGuideContextExample06() {
- test("GuideContextExample06") { guide.context.example06.main(emptyArray()) }.verifyLines(
- "job1: I have my own context and execute independently!",
- "job2: I am a child of the request coroutine",
- "job1: I am not affected by cancellation of the request",
- "main: Who has survived request cancellation?"
- )
- }
-
- @Test
- fun testGuideContextExample07() {
- test("GuideContextExample07") { guide.context.example07.main(emptyArray()) }.verifyLines(
- "job: I am a child of the request coroutine, but with a different dispatcher",
- "main: Who has survived request cancellation?"
- )
- }
-
- @Test
- fun testGuideContextExample08() {
- test("GuideContextExample08") { guide.context.example08.main(emptyArray()) }.verifyLines(
- "request: I'm done and I don't explicitly join my children that are still active",
- "Coroutine 0 is done",
- "Coroutine 1 is done",
- "Coroutine 2 is done",
- "Now processing of the request is complete"
- )
- }
-
- @Test
- fun testGuideContextExample09() {
- test("GuideContextExample09") { guide.context.example09.main(emptyArray()) }.verifyLinesFlexibleThread(
- "[main @main#1] Started main coroutine",
- "[ForkJoinPool.commonPool-worker-1 @v1coroutine#2] Computing v1",
- "[ForkJoinPool.commonPool-worker-2 @v2coroutine#3] Computing v2",
- "[main @main#1] The answer for v1 / v2 = 42"
- )
- }
-
- @Test
- fun testGuideContextExample10() {
- test("GuideContextExample10") { guide.context.example10.main(emptyArray()) }.verifyLines(
- "Launched 10 coroutines",
- "Coroutine 0 is done",
- "Coroutine 1 is done",
- "Cancelling the job!"
- )
- }
-
- @Test
- fun testGuideChannelExample01() {
- test("GuideChannelExample01") { guide.channel.example01.main(emptyArray()) }.verifyLines(
- "1",
- "4",
- "9",
- "16",
- "25",
- "Done!"
- )
- }
-
- @Test
- fun testGuideChannelExample02() {
- test("GuideChannelExample02") { guide.channel.example02.main(emptyArray()) }.verifyLines(
- "1",
- "4",
- "9",
- "16",
- "25",
- "Done!"
- )
- }
-
- @Test
- fun testGuideChannelExample03() {
- test("GuideChannelExample03") { guide.channel.example03.main(emptyArray()) }.verifyLines(
- "1",
- "4",
- "9",
- "16",
- "25",
- "Done!"
- )
- }
-
- @Test
- fun testGuideChannelExample04() {
- test("GuideChannelExample04") { guide.channel.example04.main(emptyArray()) }.verifyLines(
- "1",
- "4",
- "9",
- "16",
- "25",
- "Done!"
- )
- }
-
- @Test
- fun testGuideChannelExample05() {
- test("GuideChannelExample05") { guide.channel.example05.main(emptyArray()) }.verifyLines(
- "2",
- "3",
- "5",
- "7",
- "11",
- "13",
- "17",
- "19",
- "23",
- "29"
- )
- }
-
- @Test
- fun testGuideChannelExample06() {
- test("GuideChannelExample06") { guide.channel.example06.main(emptyArray()) }.also { lines ->
- check(lines.size == 10 && lines.withIndex().all { (i, line) -> line.startsWith("Processor #") && line.endsWith(" received ${i + 1}") })
- }
- }
-
- @Test
- fun testGuideChannelExample07() {
- test("GuideChannelExample07") { guide.channel.example07.main(emptyArray()) }.verifyLines(
- "foo",
- "foo",
- "BAR!",
- "foo",
- "foo",
- "BAR!"
- )
- }
-
- @Test
- fun testGuideChannelExample08() {
- test("GuideChannelExample08") { guide.channel.example08.main(emptyArray()) }.verifyLines(
- "Sending 0",
- "Sending 1",
- "Sending 2",
- "Sending 3",
- "Sending 4"
- )
- }
-
- @Test
- fun testGuideChannelExample10() {
- test("GuideChannelExample10") { guide.channel.example10.main(emptyArray()) }.verifyLines(
- "Initial element is available immediately: kotlin.Unit",
- "Next element is not ready in 50 ms: null",
- "Next element is ready in 100 ms: kotlin.Unit",
- "Consumer pauses for 150ms",
- "Next element is available immediately after large consumer delay: kotlin.Unit",
- "Next element is ready in 50ms after consumer pause in 150ms: kotlin.Unit"
- )
- }
-
- @Test
- fun testGuideChannelExample09() {
- test("GuideChannelExample09") { guide.channel.example09.main(emptyArray()) }.verifyLines(
- "ping Ball(hits=1)",
- "pong Ball(hits=2)",
- "ping Ball(hits=3)",
- "pong Ball(hits=4)"
- )
- }
-
- @Test
- fun testGuideSyncExample01() {
- test("GuideSyncExample01") { guide.sync.example01.main(emptyArray()) }.verifyLinesStart(
- "Completed 1000000 actions in",
- "Counter ="
- )
- }
-
- @Test
- fun testGuideSyncExample01b() {
- test("GuideSyncExample01b") { guide.sync.example01b.main(emptyArray()) }.verifyLinesStart(
- "Completed 1000000 actions in",
- "Counter ="
- )
- }
-
- @Test
- fun testGuideSyncExample02() {
- test("GuideSyncExample02") { guide.sync.example02.main(emptyArray()) }.verifyLinesStart(
- "Completed 1000000 actions in",
- "Counter ="
- )
- }
-
- @Test
- fun testGuideSyncExample03() {
- test("GuideSyncExample03") { guide.sync.example03.main(emptyArray()) }.verifyLinesArbitraryTime(
- "Completed 1000000 actions in xxx ms",
- "Counter = 1000000"
- )
- }
-
- @Test
- fun testGuideSyncExample04() {
- test("GuideSyncExample04") { guide.sync.example04.main(emptyArray()) }.verifyLinesArbitraryTime(
- "Completed 1000000 actions in xxx ms",
- "Counter = 1000000"
- )
- }
-
- @Test
- fun testGuideSyncExample05() {
- test("GuideSyncExample05") { guide.sync.example05.main(emptyArray()) }.verifyLinesArbitraryTime(
- "Completed 1000000 actions in xxx ms",
- "Counter = 1000000"
- )
- }
-
- @Test
- fun testGuideSyncExample06() {
- test("GuideSyncExample06") { guide.sync.example06.main(emptyArray()) }.verifyLinesArbitraryTime(
- "Completed 1000000 actions in xxx ms",
- "Counter = 1000000"
- )
- }
-
- @Test
- fun testGuideSyncExample07() {
- test("GuideSyncExample07") { guide.sync.example07.main(emptyArray()) }.verifyLinesArbitraryTime(
- "Completed 1000000 actions in xxx ms",
- "Counter = 1000000"
- )
- }
-
- @Test
- fun testGuideSelectExample01() {
- test("GuideSelectExample01") { guide.select.example01.main(emptyArray()) }.verifyLines(
- "fizz -> 'Fizz'",
- "buzz -> 'Buzz!'",
- "fizz -> 'Fizz'",
- "fizz -> 'Fizz'",
- "buzz -> 'Buzz!'",
- "fizz -> 'Fizz'",
- "buzz -> 'Buzz!'"
- )
- }
-
- @Test
- fun testGuideSelectExample02() {
- test("GuideSelectExample02") { guide.select.example02.main(emptyArray()) }.verifyLines(
- "a -> 'Hello 0'",
- "a -> 'Hello 1'",
- "b -> 'World 0'",
- "a -> 'Hello 2'",
- "a -> 'Hello 3'",
- "b -> 'World 1'",
- "Channel 'a' is closed",
- "Channel 'a' is closed"
- )
- }
-
- @Test
- fun testGuideSelectExample03() {
- test("GuideSelectExample03") { guide.select.example03.main(emptyArray()) }.verifyLines(
- "Consuming 1",
- "Side channel has 2",
- "Side channel has 3",
- "Consuming 4",
- "Side channel has 5",
- "Side channel has 6",
- "Consuming 7",
- "Side channel has 8",
- "Side channel has 9",
- "Consuming 10",
- "Done consuming"
- )
- }
-
- @Test
- fun testGuideSelectExample04() {
- test("GuideSelectExample04") { guide.select.example04.main(emptyArray()) }.verifyLines(
- "Deferred 4 produced answer 'Waited for 128 ms'",
- "11 coroutines are still active"
- )
- }
-
- @Test
- fun testGuideSelectExample05() {
- test("GuideSelectExample05") { guide.select.example05.main(emptyArray()) }.verifyLines(
- "BEGIN",
- "Replace",
- "END",
- "Channel was closed"
- )
- }
-}
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/test/TestCoroutineContext.kt b/core/kotlinx-coroutines-core/src/test_/TestCoroutineContext.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/test/TestCoroutineContext.kt
rename to core/kotlinx-coroutines-core/src/test_/TestCoroutineContext.kt
diff --git a/core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/timeunit/TimeUnit.kt b/core/kotlinx-coroutines-core/src/timeunit/TimeUnit.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/main/kotlin/kotlinx/coroutines/experimental/timeunit/TimeUnit.kt
rename to core/kotlinx-coroutines-core/src/timeunit/TimeUnit.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/AsyncJvmTest.kt b/core/kotlinx-coroutines-core/test/AsyncJvmTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/AsyncJvmTest.kt
rename to core/kotlinx-coroutines-core/test/AsyncJvmTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/AtomicCancellationTest.kt b/core/kotlinx-coroutines-core/test/AtomicCancellationTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/AtomicCancellationTest.kt
rename to core/kotlinx-coroutines-core/test/AtomicCancellationTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/AwaitJvmTest.kt b/core/kotlinx-coroutines-core/test/AwaitJvmTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/AwaitJvmTest.kt
rename to core/kotlinx-coroutines-core/test/AwaitJvmTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/AwaitStressTest.kt b/core/kotlinx-coroutines-core/test/AwaitStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/AwaitStressTest.kt
rename to core/kotlinx-coroutines-core/test/AwaitStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/CancellableContinuationExceptionHandlingTest.kt b/core/kotlinx-coroutines-core/test/CancellableContinuationExceptionHandlingTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/CancellableContinuationExceptionHandlingTest.kt
rename to core/kotlinx-coroutines-core/test/CancellableContinuationExceptionHandlingTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/CoroutinesJvmTest.kt b/core/kotlinx-coroutines-core/test/CoroutinesJvmTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/CoroutinesJvmTest.kt
rename to core/kotlinx-coroutines-core/test/CoroutinesJvmTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/DefaultExecutorStressTest.kt b/core/kotlinx-coroutines-core/test/DefaultExecutorStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/DefaultExecutorStressTest.kt
rename to core/kotlinx-coroutines-core/test/DefaultExecutorStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/DelayJvmTest.kt b/core/kotlinx-coroutines-core/test/DelayJvmTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/DelayJvmTest.kt
rename to core/kotlinx-coroutines-core/test/DelayJvmTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/ExecutorsTest.kt b/core/kotlinx-coroutines-core/test/ExecutorsTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/ExecutorsTest.kt
rename to core/kotlinx-coroutines-core/test/ExecutorsTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/JobDisposeTest.kt b/core/kotlinx-coroutines-core/test/JobDisposeTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/JobDisposeTest.kt
rename to core/kotlinx-coroutines-core/test/JobDisposeTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/JobHandlersUpgradeStressTest.kt b/core/kotlinx-coroutines-core/test/JobHandlersUpgradeStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/JobHandlersUpgradeStressTest.kt
rename to core/kotlinx-coroutines-core/test/JobHandlersUpgradeStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/JobStressTest.kt b/core/kotlinx-coroutines-core/test/JobStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/JobStressTest.kt
rename to core/kotlinx-coroutines-core/test/JobStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/JoinStressTest.kt b/core/kotlinx-coroutines-core/test/JoinStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/JoinStressTest.kt
rename to core/kotlinx-coroutines-core/test/JoinStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/LinTesting.kt b/core/kotlinx-coroutines-core/test/LinTesting.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/LinTesting.kt
rename to core/kotlinx-coroutines-core/test/LinTesting.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/RunBlockingTest.kt b/core/kotlinx-coroutines-core/test/RunBlockingTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/RunBlockingTest.kt
rename to core/kotlinx-coroutines-core/test/RunBlockingTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/TestBase.kt b/core/kotlinx-coroutines-core/test/TestBase.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/TestBase.kt
rename to core/kotlinx-coroutines-core/test/TestBase.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/TestBaseTest.kt b/core/kotlinx-coroutines-core/test/TestBaseTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/TestBaseTest.kt
rename to core/kotlinx-coroutines-core/test/TestBaseTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/TestSecurityManager.kt b/core/kotlinx-coroutines-core/test/TestSecurityManager.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/TestSecurityManager.kt
rename to core/kotlinx-coroutines-core/test/TestSecurityManager.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/Threads.kt b/core/kotlinx-coroutines-core/test/Threads.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/Threads.kt
rename to core/kotlinx-coroutines-core/test/Threads.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/WithContextCancellationStressTest.kt b/core/kotlinx-coroutines-core/test/WithContextCancellationStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/WithContextCancellationStressTest.kt
rename to core/kotlinx-coroutines-core/test/WithContextCancellationStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/WithContextCommonPoolTest.kt b/core/kotlinx-coroutines-core/test/WithContextCommonPoolTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/WithContextCommonPoolTest.kt
rename to core/kotlinx-coroutines-core/test/WithContextCommonPoolTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/WithTimeoutOrNullJvmTest.kt b/core/kotlinx-coroutines-core/test/WithTimeoutOrNullJvmTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/WithTimeoutOrNullJvmTest.kt
rename to core/kotlinx-coroutines-core/test/WithTimeoutOrNullJvmTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/WithTimeoutOrNullThreadDispatchTest.kt b/core/kotlinx-coroutines-core/test/WithTimeoutOrNullThreadDispatchTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/WithTimeoutOrNullThreadDispatchTest.kt
rename to core/kotlinx-coroutines-core/test/WithTimeoutOrNullThreadDispatchTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/WithTimeoutThreadDispatchTest.kt b/core/kotlinx-coroutines-core/test/WithTimeoutThreadDispatchTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/WithTimeoutThreadDispatchTest.kt
rename to core/kotlinx-coroutines-core/test/WithTimeoutThreadDispatchTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ActorLazyTest.kt b/core/kotlinx-coroutines-core/test/channels/ActorLazyTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ActorLazyTest.kt
rename to core/kotlinx-coroutines-core/test/channels/ActorLazyTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ActorTest.kt b/core/kotlinx-coroutines-core/test/channels/ActorTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ActorTest.kt
rename to core/kotlinx-coroutines-core/test/channels/ActorTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ArrayChannelStressTest.kt b/core/kotlinx-coroutines-core/test/channels/ArrayChannelStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ArrayChannelStressTest.kt
rename to core/kotlinx-coroutines-core/test/channels/ArrayChannelStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/BroadcastChannelMultiReceiveStressTest.kt b/core/kotlinx-coroutines-core/test/channels/BroadcastChannelMultiReceiveStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/BroadcastChannelMultiReceiveStressTest.kt
rename to core/kotlinx-coroutines-core/test/channels/BroadcastChannelMultiReceiveStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/BroadcastChannelSubStressTest.kt b/core/kotlinx-coroutines-core/test/channels/BroadcastChannelSubStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/BroadcastChannelSubStressTest.kt
rename to core/kotlinx-coroutines-core/test/channels/BroadcastChannelSubStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ChannelAtomicCancelStressTest.kt b/core/kotlinx-coroutines-core/test/channels/ChannelAtomicCancelStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ChannelAtomicCancelStressTest.kt
rename to core/kotlinx-coroutines-core/test/channels/ChannelAtomicCancelStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ChannelLinearizabilityTest.kt b/core/kotlinx-coroutines-core/test/channels/ChannelLinearizabilityTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ChannelLinearizabilityTest.kt
rename to core/kotlinx-coroutines-core/test/channels/ChannelLinearizabilityTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ChannelSendReceiveStressTest.kt b/core/kotlinx-coroutines-core/test/channels/ChannelSendReceiveStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ChannelSendReceiveStressTest.kt
rename to core/kotlinx-coroutines-core/test/channels/ChannelSendReceiveStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ChannelsConsumeTest.kt b/core/kotlinx-coroutines-core/test/channels/ChannelsConsumeTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ChannelsConsumeTest.kt
rename to core/kotlinx-coroutines-core/test/channels/ChannelsConsumeTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ChannelsJvmTest.kt b/core/kotlinx-coroutines-core/test/channels/ChannelsJvmTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ChannelsJvmTest.kt
rename to core/kotlinx-coroutines-core/test/channels/ChannelsJvmTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ConflatedBroadcastChannelNotifyStressTest.kt b/core/kotlinx-coroutines-core/test/channels/ConflatedBroadcastChannelNotifyStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ConflatedBroadcastChannelNotifyStressTest.kt
rename to core/kotlinx-coroutines-core/test/channels/ConflatedBroadcastChannelNotifyStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ConflatedChannelCloseStressTest.kt b/core/kotlinx-coroutines-core/test/channels/ConflatedChannelCloseStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ConflatedChannelCloseStressTest.kt
rename to core/kotlinx-coroutines-core/test/channels/ConflatedChannelCloseStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/DoubleChannelCloseStressTest.kt b/core/kotlinx-coroutines-core/test/channels/DoubleChannelCloseStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/DoubleChannelCloseStressTest.kt
rename to core/kotlinx-coroutines-core/test/channels/DoubleChannelCloseStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ProduceConsumeJvmTest.kt b/core/kotlinx-coroutines-core/test/channels/ProduceConsumeJvmTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/ProduceConsumeJvmTest.kt
rename to core/kotlinx-coroutines-core/test/channels/ProduceConsumeJvmTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/RandevouzChannelStressTest.kt b/core/kotlinx-coroutines-core/test/channels/RandevouzChannelStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/RandevouzChannelStressTest.kt
rename to core/kotlinx-coroutines-core/test/channels/RandevouzChannelStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/SendReceiveJvmStressTest.kt b/core/kotlinx-coroutines-core/test/channels/SendReceiveJvmStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/SendReceiveJvmStressTest.kt
rename to core/kotlinx-coroutines-core/test/channels/SendReceiveJvmStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/SimpleSendReceiveJvmTest.kt b/core/kotlinx-coroutines-core/test/channels/SimpleSendReceiveJvmTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/SimpleSendReceiveJvmTest.kt
rename to core/kotlinx-coroutines-core/test/channels/SimpleSendReceiveJvmTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/TickerChannelCommonTest.kt b/core/kotlinx-coroutines-core/test/channels/TickerChannelCommonTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/TickerChannelCommonTest.kt
rename to core/kotlinx-coroutines-core/test/channels/TickerChannelCommonTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/TickerChannelTest.kt b/core/kotlinx-coroutines-core/test/channels/TickerChannelTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/channels/TickerChannelTest.kt
rename to core/kotlinx-coroutines-core/test/channels/TickerChannelTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-01.kt b/core/kotlinx-coroutines-core/test/guide/example-basic-01.kt
similarity index 95%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-01.kt
rename to core/kotlinx-coroutines-core/test/guide/example-basic-01.kt
index 4b12fde..54882c4 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-01.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-basic-01.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.basic.example01
+package kotlinx.coroutines.experimental.guide.basic01
import kotlinx.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-02.kt b/core/kotlinx-coroutines-core/test/guide/example-basic-02.kt
similarity index 95%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-02.kt
rename to core/kotlinx-coroutines-core/test/guide/example-basic-02.kt
index 0060677..29ebee3 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-02.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-basic-02.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.basic.example02
+package kotlinx.coroutines.experimental.guide.basic02
import kotlinx.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-02b.kt b/core/kotlinx-coroutines-core/test/guide/example-basic-02b.kt
similarity index 94%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-02b.kt
rename to core/kotlinx-coroutines-core/test/guide/example-basic-02b.kt
index 282e6a2..813eaa9 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-02b.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-basic-02b.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.basic.example02b
+package kotlinx.coroutines.experimental.guide.basic02b
import kotlinx.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-03.kt b/core/kotlinx-coroutines-core/test/guide/example-basic-03.kt
similarity index 94%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-03.kt
rename to core/kotlinx-coroutines-core/test/guide/example-basic-03.kt
index cfb9b8c..0d1a1a3 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-03.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-basic-03.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.basic.example03
+package kotlinx.coroutines.experimental.guide.basic03
import kotlinx.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-04.kt b/core/kotlinx-coroutines-core/test/guide/example-basic-04.kt
similarity index 94%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-04.kt
rename to core/kotlinx-coroutines-core/test/guide/example-basic-04.kt
index f7f0809..d987fca 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-04.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-basic-04.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.basic.example04
+package kotlinx.coroutines.experimental.guide.basic04
import kotlinx.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-05.kt b/core/kotlinx-coroutines-core/test/guide/example-basic-05.kt
similarity index 94%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-05.kt
rename to core/kotlinx-coroutines-core/test/guide/example-basic-05.kt
index 40dc0cc..2cf1ce5 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-05.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-basic-05.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.basic.example05
+package kotlinx.coroutines.experimental.guide.basic05
import kotlinx.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-06.kt b/core/kotlinx-coroutines-core/test/guide/example-basic-06.kt
similarity index 94%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-06.kt
rename to core/kotlinx-coroutines-core/test/guide/example-basic-06.kt
index 1e28111..41e6916 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-06.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-basic-06.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.basic.example06
+package kotlinx.coroutines.experimental.guide.basic06
import kotlinx.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-01.kt b/core/kotlinx-coroutines-core/test/guide/example-cancel-01.kt
similarity index 95%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-01.kt
rename to core/kotlinx-coroutines-core/test/guide/example-cancel-01.kt
index c32c8c5..8bd969f 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-01.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-cancel-01.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.cancel.example01
+package kotlinx.coroutines.experimental.guide.cancel01
import kotlinx.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-02.kt b/core/kotlinx-coroutines-core/test/guide/example-cancel-02.kt
similarity index 95%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-02.kt
rename to core/kotlinx-coroutines-core/test/guide/example-cancel-02.kt
index 6d5d42d..406c923 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-02.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-cancel-02.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.cancel.example02
+package kotlinx.coroutines.experimental.guide.cancel02
import kotlinx.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-03.kt b/core/kotlinx-coroutines-core/test/guide/example-cancel-03.kt
similarity index 95%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-03.kt
rename to core/kotlinx-coroutines-core/test/guide/example-cancel-03.kt
index b058717..691ca1c 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-03.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-cancel-03.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.cancel.example03
+package kotlinx.coroutines.experimental.guide.cancel03
import kotlinx.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-04.kt b/core/kotlinx-coroutines-core/test/guide/example-cancel-04.kt
similarity index 95%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-04.kt
rename to core/kotlinx-coroutines-core/test/guide/example-cancel-04.kt
index b715f8a..71a6853 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-04.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-cancel-04.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.cancel.example04
+package kotlinx.coroutines.experimental.guide.cancel04
import kotlinx.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-05.kt b/core/kotlinx-coroutines-core/test/guide/example-cancel-05.kt
similarity index 95%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-05.kt
rename to core/kotlinx-coroutines-core/test/guide/example-cancel-05.kt
index 0eb0db0..a460988 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-05.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-cancel-05.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.cancel.example05
+package kotlinx.coroutines.experimental.guide.cancel05
import kotlinx.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-06.kt b/core/kotlinx-coroutines-core/test/guide/example-cancel-06.kt
similarity index 94%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-06.kt
rename to core/kotlinx-coroutines-core/test/guide/example-cancel-06.kt
index 3320cef..b72e899 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-06.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-cancel-06.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.cancel.example06
+package kotlinx.coroutines.experimental.guide.cancel06
import kotlinx.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-07.kt b/core/kotlinx-coroutines-core/test/guide/example-cancel-07.kt
similarity index 94%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-07.kt
rename to core/kotlinx-coroutines-core/test/guide/example-cancel-07.kt
index 1a197a4..d14b8f1 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-07.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-cancel-07.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.cancel.example07
+package kotlinx.coroutines.experimental.guide.cancel07
import kotlinx.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-01.kt b/core/kotlinx-coroutines-core/test/guide/example-channel-01.kt
similarity index 95%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-01.kt
rename to core/kotlinx-coroutines-core/test/guide/example-channel-01.kt
index f7cc266..fe54569 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-01.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-channel-01.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.channel.example01
+package kotlinx.coroutines.experimental.guide.channel01
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-02.kt b/core/kotlinx-coroutines-core/test/guide/example-channel-02.kt
similarity index 94%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-02.kt
rename to core/kotlinx-coroutines-core/test/guide/example-channel-02.kt
index d7ff4c3..307f6bd 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-02.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-channel-02.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.channel.example02
+package kotlinx.coroutines.experimental.guide.channel02
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-03.kt b/core/kotlinx-coroutines-core/test/guide/example-channel-03.kt
similarity index 94%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-03.kt
rename to core/kotlinx-coroutines-core/test/guide/example-channel-03.kt
index b0cbf6a..f6279df 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-03.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-channel-03.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.channel.example03
+package kotlinx.coroutines.experimental.guide.channel03
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-04.kt b/core/kotlinx-coroutines-core/test/guide/example-channel-04.kt
similarity index 95%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-04.kt
rename to core/kotlinx-coroutines-core/test/guide/example-channel-04.kt
index d5d7852..8802ff0 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-04.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-channel-04.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.channel.example04
+package kotlinx.coroutines.experimental.guide.channel04
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-05.kt b/core/kotlinx-coroutines-core/test/guide/example-channel-05.kt
similarity index 96%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-05.kt
rename to core/kotlinx-coroutines-core/test/guide/example-channel-05.kt
index 166a4ad..40407e8 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-05.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-channel-05.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.channel.example05
+package kotlinx.coroutines.experimental.guide.channel05
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-06.kt b/core/kotlinx-coroutines-core/test/guide/example-channel-06.kt
similarity index 95%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-06.kt
rename to core/kotlinx-coroutines-core/test/guide/example-channel-06.kt
index cbe8790..9e74844 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-06.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-channel-06.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.channel.example06
+package kotlinx.coroutines.experimental.guide.channel06
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-07.kt b/core/kotlinx-coroutines-core/test/guide/example-channel-07.kt
similarity index 95%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-07.kt
rename to core/kotlinx-coroutines-core/test/guide/example-channel-07.kt
index ee74930..f0ec5c0 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-07.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-channel-07.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.channel.example07
+package kotlinx.coroutines.experimental.guide.channel07
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-08.kt b/core/kotlinx-coroutines-core/test/guide/example-channel-08.kt
similarity index 95%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-08.kt
rename to core/kotlinx-coroutines-core/test/guide/example-channel-08.kt
index 484cd88..48cbce8 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-08.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-channel-08.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.channel.example08
+package kotlinx.coroutines.experimental.guide.channel08
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-09.kt b/core/kotlinx-coroutines-core/test/guide/example-channel-09.kt
similarity index 96%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-09.kt
rename to core/kotlinx-coroutines-core/test/guide/example-channel-09.kt
index fe93386..013352d 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-09.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-channel-09.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.channel.example09
+package kotlinx.coroutines.experimental.guide.channel09
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-10.kt b/core/kotlinx-coroutines-core/test/guide/example-channel-10.kt
similarity index 97%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-10.kt
rename to core/kotlinx-coroutines-core/test/guide/example-channel-10.kt
index e294610..a1bbbcf 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-10.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-channel-10.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.channel.example10
+package kotlinx.coroutines.experimental.guide.channel10
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-compose-01.kt b/core/kotlinx-coroutines-core/test/guide/example-compose-01.kt
similarity index 95%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-compose-01.kt
rename to core/kotlinx-coroutines-core/test/guide/example-compose-01.kt
index d4a0901..2a03474 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-compose-01.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-compose-01.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.compose.example01
+package kotlinx.coroutines.experimental.guide.compose01
import kotlinx.coroutines.experimental.*
import kotlin.system.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-compose-02.kt b/core/kotlinx-coroutines-core/test/guide/example-compose-02.kt
similarity index 95%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-compose-02.kt
rename to core/kotlinx-coroutines-core/test/guide/example-compose-02.kt
index b6dfd4a..1ff00d5 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-compose-02.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-compose-02.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.compose.example02
+package kotlinx.coroutines.experimental.guide.compose02
import kotlinx.coroutines.experimental.*
import kotlin.system.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-compose-03.kt b/core/kotlinx-coroutines-core/test/guide/example-compose-03.kt
similarity index 95%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-compose-03.kt
rename to core/kotlinx-coroutines-core/test/guide/example-compose-03.kt
index d3745fe..a6d6110 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-compose-03.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-compose-03.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.compose.example03
+package kotlinx.coroutines.experimental.guide.compose03
import kotlinx.coroutines.experimental.*
import kotlin.system.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-compose-04.kt b/core/kotlinx-coroutines-core/test/guide/example-compose-04.kt
similarity index 96%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-compose-04.kt
rename to core/kotlinx-coroutines-core/test/guide/example-compose-04.kt
index f85002c..c13fd72 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-compose-04.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-compose-04.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.compose.example04
+package kotlinx.coroutines.experimental.guide.compose04
import kotlinx.coroutines.experimental.*
import kotlin.system.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-01.kt b/core/kotlinx-coroutines-core/test/guide/example-context-01.kt
similarity index 96%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-01.kt
rename to core/kotlinx-coroutines-core/test/guide/example-context-01.kt
index 9472d06..1ddad0e 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-01.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-context-01.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.context.example01
+package kotlinx.coroutines.experimental.guide.context01
import kotlinx.coroutines.experimental.*
import kotlin.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-02.kt b/core/kotlinx-coroutines-core/test/guide/example-context-02.kt
similarity index 96%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-02.kt
rename to core/kotlinx-coroutines-core/test/guide/example-context-02.kt
index a62929f..05378df 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-02.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-context-02.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.context.example02
+package kotlinx.coroutines.experimental.guide.context02
import kotlinx.coroutines.experimental.*
import kotlin.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-03.kt b/core/kotlinx-coroutines-core/test/guide/example-context-03.kt
similarity index 95%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-03.kt
rename to core/kotlinx-coroutines-core/test/guide/example-context-03.kt
index 86b3004..2a8b1c4 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-03.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-context-03.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.context.example03
+package kotlinx.coroutines.experimental.guide.context03
import kotlinx.coroutines.experimental.*
import kotlin.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-04.kt b/core/kotlinx-coroutines-core/test/guide/example-context-04.kt
similarity index 95%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-04.kt
rename to core/kotlinx-coroutines-core/test/guide/example-context-04.kt
index 0c20fc8..f2604ea 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-04.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-context-04.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.context.example04
+package kotlinx.coroutines.experimental.guide.context04
import kotlinx.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-05.kt b/core/kotlinx-coroutines-core/test/guide/example-context-05.kt
similarity index 93%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-05.kt
rename to core/kotlinx-coroutines-core/test/guide/example-context-05.kt
index 8eb44ff..17523a7 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-05.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-context-05.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.context.example05
+package kotlinx.coroutines.experimental.guide.context05
import kotlinx.coroutines.experimental.*
import kotlin.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-06.kt b/core/kotlinx-coroutines-core/test/guide/example-context-06.kt
similarity index 96%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-06.kt
rename to core/kotlinx-coroutines-core/test/guide/example-context-06.kt
index ecb012c..cc0d78f 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-06.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-context-06.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.context.example06
+package kotlinx.coroutines.experimental.guide.context06
import kotlinx.coroutines.experimental.*
import kotlin.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-07.kt b/core/kotlinx-coroutines-core/test/guide/example-context-07.kt
similarity index 96%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-07.kt
rename to core/kotlinx-coroutines-core/test/guide/example-context-07.kt
index 1093685..2bb34c3 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-07.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-context-07.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.context.example07
+package kotlinx.coroutines.experimental.guide.context07
import kotlinx.coroutines.experimental.*
import kotlin.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-08.kt b/core/kotlinx-coroutines-core/test/guide/example-context-08.kt
similarity index 95%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-08.kt
rename to core/kotlinx-coroutines-core/test/guide/example-context-08.kt
index 7f2fc2b..ac2c00e 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-08.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-context-08.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.context.example08
+package kotlinx.coroutines.experimental.guide.context08
import kotlinx.coroutines.experimental.*
import kotlin.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-09.kt b/core/kotlinx-coroutines-core/test/guide/example-context-09.kt
similarity index 95%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-09.kt
rename to core/kotlinx-coroutines-core/test/guide/example-context-09.kt
index cc2462c..ae5f62d 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-09.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-context-09.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.context.example09
+package kotlinx.coroutines.experimental.guide.context09
import kotlinx.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-10.kt b/core/kotlinx-coroutines-core/test/guide/example-context-10.kt
similarity index 96%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-10.kt
rename to core/kotlinx-coroutines-core/test/guide/example-context-10.kt
index ad98c11..7104350 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-10.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-context-10.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.context.example10
+package kotlinx.coroutines.experimental.guide.context10
import kotlinx.coroutines.experimental.*
import kotlin.coroutines.experimental.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-select-01.kt b/core/kotlinx-coroutines-core/test/guide/example-select-01.kt
similarity index 96%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-select-01.kt
rename to core/kotlinx-coroutines-core/test/guide/example-select-01.kt
index 9a07954..6a6b513 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-select-01.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-select-01.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.select.example01
+package kotlinx.coroutines.experimental.guide.select01
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-select-02.kt b/core/kotlinx-coroutines-core/test/guide/example-select-02.kt
similarity index 96%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-select-02.kt
rename to core/kotlinx-coroutines-core/test/guide/example-select-02.kt
index ee8421b..ab78997 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-select-02.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-select-02.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.select.example02
+package kotlinx.coroutines.experimental.guide.select02
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-select-03.kt b/core/kotlinx-coroutines-core/test/guide/example-select-03.kt
similarity index 96%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-select-03.kt
rename to core/kotlinx-coroutines-core/test/guide/example-select-03.kt
index 4674e9f..a0d8570 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-select-03.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-select-03.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.select.example03
+package kotlinx.coroutines.experimental.guide.select03
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-select-04.kt b/core/kotlinx-coroutines-core/test/guide/example-select-04.kt
similarity index 96%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-select-04.kt
rename to core/kotlinx-coroutines-core/test/guide/example-select-04.kt
index aae5843..4a89cf2 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-select-04.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-select-04.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.select.example04
+package kotlinx.coroutines.experimental.guide.select04
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-select-05.kt b/core/kotlinx-coroutines-core/test/guide/example-select-05.kt
similarity index 97%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-select-05.kt
rename to core/kotlinx-coroutines-core/test/guide/example-select-05.kt
index ba02006..30cbbc5 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-select-05.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-select-05.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.select.example05
+package kotlinx.coroutines.experimental.guide.select05
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-01.kt b/core/kotlinx-coroutines-core/test/guide/example-sync-01.kt
similarity index 96%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-01.kt
rename to core/kotlinx-coroutines-core/test/guide/example-sync-01.kt
index b761c7d..d790b9e 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-01.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-sync-01.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.sync.example01
+package kotlinx.coroutines.experimental.guide.sync01
import kotlinx.coroutines.experimental.*
import kotlin.system.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-01b.kt b/core/kotlinx-coroutines-core/test/guide/example-sync-01b.kt
similarity index 96%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-01b.kt
rename to core/kotlinx-coroutines-core/test/guide/example-sync-01b.kt
index c032747..19a68f3 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-01b.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-sync-01b.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.sync.example01b
+package kotlinx.coroutines.experimental.guide.sync01b
import kotlinx.coroutines.experimental.*
import kotlin.system.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-02.kt b/core/kotlinx-coroutines-core/test/guide/example-sync-02.kt
similarity index 96%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-02.kt
rename to core/kotlinx-coroutines-core/test/guide/example-sync-02.kt
index e5cf125..39bfef1 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-02.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-sync-02.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.sync.example02
+package kotlinx.coroutines.experimental.guide.sync02
import kotlinx.coroutines.experimental.*
import kotlin.system.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-03.kt b/core/kotlinx-coroutines-core/test/guide/example-sync-03.kt
similarity index 96%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-03.kt
rename to core/kotlinx-coroutines-core/test/guide/example-sync-03.kt
index 37dd5d8..83354bd 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-03.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-sync-03.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.sync.example03
+package kotlinx.coroutines.experimental.guide.sync03
import kotlinx.coroutines.experimental.*
import java.util.concurrent.atomic.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-04.kt b/core/kotlinx-coroutines-core/test/guide/example-sync-04.kt
similarity index 96%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-04.kt
rename to core/kotlinx-coroutines-core/test/guide/example-sync-04.kt
index bd69d12..a70d308 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-04.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-sync-04.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.sync.example04
+package kotlinx.coroutines.experimental.guide.sync04
import kotlinx.coroutines.experimental.*
import kotlin.system.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-05.kt b/core/kotlinx-coroutines-core/test/guide/example-sync-05.kt
similarity index 96%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-05.kt
rename to core/kotlinx-coroutines-core/test/guide/example-sync-05.kt
index cfd5c19..9deed70 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-05.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-sync-05.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.sync.example05
+package kotlinx.coroutines.experimental.guide.sync05
import kotlinx.coroutines.experimental.*
import kotlin.system.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-06.kt b/core/kotlinx-coroutines-core/test/guide/example-sync-06.kt
similarity index 96%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-06.kt
rename to core/kotlinx-coroutines-core/test/guide/example-sync-06.kt
index 73702dd..7c8fe9c 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-06.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-sync-06.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.sync.example06
+package kotlinx.coroutines.experimental.guide.sync06
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.sync.*
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-07.kt b/core/kotlinx-coroutines-core/test/guide/example-sync-07.kt
similarity index 97%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-07.kt
rename to core/kotlinx-coroutines-core/test/guide/example-sync-07.kt
index 4d00d7c..33b06ae 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-07.kt
+++ b/core/kotlinx-coroutines-core/test/guide/example-sync-07.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.sync.example07
+package kotlinx.coroutines.experimental.guide.sync07
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/core/kotlinx-coroutines-core/test/guide/test/GuideTest.kt b/core/kotlinx-coroutines-core/test/guide/test/GuideTest.kt
new file mode 100644
index 0000000..1c51a9b
--- /dev/null
+++ b/core/kotlinx-coroutines-core/test/guide/test/GuideTest.kt
@@ -0,0 +1,511 @@
+// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
+package kotlinx.coroutines.experimental.guide.test
+
+import org.junit.Test
+
+class GuideTest {
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideBasic01() {
+ test("KotlinxCoroutinesExperimentalGuideBasic01") { kotlinx.coroutines.experimental.guide.basic01.main(emptyArray()) }.verifyLines(
+ "Hello,",
+ "World!"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideBasic02() {
+ test("KotlinxCoroutinesExperimentalGuideBasic02") { kotlinx.coroutines.experimental.guide.basic02.main(emptyArray()) }.verifyLines(
+ "Hello,",
+ "World!"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideBasic02b() {
+ test("KotlinxCoroutinesExperimentalGuideBasic02b") { kotlinx.coroutines.experimental.guide.basic02b.main(emptyArray()) }.verifyLines(
+ "Hello,",
+ "World!"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideBasic03() {
+ test("KotlinxCoroutinesExperimentalGuideBasic03") { kotlinx.coroutines.experimental.guide.basic03.main(emptyArray()) }.verifyLines(
+ "Hello,",
+ "World!"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideBasic04() {
+ test("KotlinxCoroutinesExperimentalGuideBasic04") { kotlinx.coroutines.experimental.guide.basic04.main(emptyArray()) }.verifyLines(
+ "Hello,",
+ "World!"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideBasic05() {
+ test("KotlinxCoroutinesExperimentalGuideBasic05") { kotlinx.coroutines.experimental.guide.basic05.main(emptyArray()) }.also { lines ->
+ check(lines.size == 1 && lines[0] == ".".repeat(100_000))
+ }
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideBasic06() {
+ test("KotlinxCoroutinesExperimentalGuideBasic06") { kotlinx.coroutines.experimental.guide.basic06.main(emptyArray()) }.verifyLines(
+ "I'm sleeping 0 ...",
+ "I'm sleeping 1 ...",
+ "I'm sleeping 2 ..."
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideCancel01() {
+ test("KotlinxCoroutinesExperimentalGuideCancel01") { kotlinx.coroutines.experimental.guide.cancel01.main(emptyArray()) }.verifyLines(
+ "I'm sleeping 0 ...",
+ "I'm sleeping 1 ...",
+ "I'm sleeping 2 ...",
+ "main: I'm tired of waiting!",
+ "main: Now I can quit."
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideCancel02() {
+ test("KotlinxCoroutinesExperimentalGuideCancel02") { kotlinx.coroutines.experimental.guide.cancel02.main(emptyArray()) }.verifyLines(
+ "I'm sleeping 0 ...",
+ "I'm sleeping 1 ...",
+ "I'm sleeping 2 ...",
+ "main: I'm tired of waiting!",
+ "I'm sleeping 3 ...",
+ "I'm sleeping 4 ...",
+ "main: Now I can quit."
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideCancel03() {
+ test("KotlinxCoroutinesExperimentalGuideCancel03") { kotlinx.coroutines.experimental.guide.cancel03.main(emptyArray()) }.verifyLines(
+ "I'm sleeping 0 ...",
+ "I'm sleeping 1 ...",
+ "I'm sleeping 2 ...",
+ "main: I'm tired of waiting!",
+ "main: Now I can quit."
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideCancel04() {
+ test("KotlinxCoroutinesExperimentalGuideCancel04") { kotlinx.coroutines.experimental.guide.cancel04.main(emptyArray()) }.verifyLines(
+ "I'm sleeping 0 ...",
+ "I'm sleeping 1 ...",
+ "I'm sleeping 2 ...",
+ "main: I'm tired of waiting!",
+ "I'm running finally",
+ "main: Now I can quit."
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideCancel05() {
+ test("KotlinxCoroutinesExperimentalGuideCancel05") { kotlinx.coroutines.experimental.guide.cancel05.main(emptyArray()) }.verifyLines(
+ "I'm sleeping 0 ...",
+ "I'm sleeping 1 ...",
+ "I'm sleeping 2 ...",
+ "main: I'm tired of waiting!",
+ "I'm running finally",
+ "And I've just delayed for 1 sec because I'm non-cancellable",
+ "main: Now I can quit."
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideCancel06() {
+ test("KotlinxCoroutinesExperimentalGuideCancel06") { kotlinx.coroutines.experimental.guide.cancel06.main(emptyArray()) }.verifyLinesStartWith(
+ "I'm sleeping 0 ...",
+ "I'm sleeping 1 ...",
+ "I'm sleeping 2 ...",
+ "Exception in thread \"main\" kotlinx.coroutines.experimental.TimeoutCancellationException: Timed out waiting for 1300 MILLISECONDS"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideCancel07() {
+ test("KotlinxCoroutinesExperimentalGuideCancel07") { kotlinx.coroutines.experimental.guide.cancel07.main(emptyArray()) }.verifyLines(
+ "I'm sleeping 0 ...",
+ "I'm sleeping 1 ...",
+ "I'm sleeping 2 ...",
+ "Result is null"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideCompose01() {
+ test("KotlinxCoroutinesExperimentalGuideCompose01") { kotlinx.coroutines.experimental.guide.compose01.main(emptyArray()) }.verifyLinesArbitraryTime(
+ "The answer is 42",
+ "Completed in 2017 ms"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideCompose02() {
+ test("KotlinxCoroutinesExperimentalGuideCompose02") { kotlinx.coroutines.experimental.guide.compose02.main(emptyArray()) }.verifyLinesArbitraryTime(
+ "The answer is 42",
+ "Completed in 1017 ms"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideCompose03() {
+ test("KotlinxCoroutinesExperimentalGuideCompose03") { kotlinx.coroutines.experimental.guide.compose03.main(emptyArray()) }.verifyLinesArbitraryTime(
+ "The answer is 42",
+ "Completed in 2017 ms"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideCompose04() {
+ test("KotlinxCoroutinesExperimentalGuideCompose04") { kotlinx.coroutines.experimental.guide.compose04.main(emptyArray()) }.verifyLinesArbitraryTime(
+ "The answer is 42",
+ "Completed in 1085 ms"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideContext01() {
+ test("KotlinxCoroutinesExperimentalGuideContext01") { kotlinx.coroutines.experimental.guide.context01.main(emptyArray()) }.verifyLinesStartUnordered(
+ " 'Unconfined': I'm working in thread main",
+ " 'CommonPool': I'm working in thread ForkJoinPool.commonPool-worker-1",
+ " 'newSTC': I'm working in thread MyOwnThread",
+ "'coroutineContext': I'm working in thread main"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideContext02() {
+ test("KotlinxCoroutinesExperimentalGuideContext02") { kotlinx.coroutines.experimental.guide.context02.main(emptyArray()) }.verifyLinesStart(
+ " 'Unconfined': I'm working in thread main",
+ "'coroutineContext': I'm working in thread main",
+ " 'Unconfined': After delay in thread kotlinx.coroutines.DefaultExecutor",
+ "'coroutineContext': After delay in thread main"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideContext03() {
+ test("KotlinxCoroutinesExperimentalGuideContext03") { kotlinx.coroutines.experimental.guide.context03.main(emptyArray()) }.verifyLinesFlexibleThread(
+ "[main @coroutine#2] I'm computing a piece of the answer",
+ "[main @coroutine#3] I'm computing another piece of the answer",
+ "[main @coroutine#1] The answer is 42"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideContext04() {
+ test("KotlinxCoroutinesExperimentalGuideContext04") { kotlinx.coroutines.experimental.guide.context04.main(emptyArray()) }.verifyLines(
+ "[Ctx1 @coroutine#1] Started in ctx1",
+ "[Ctx2 @coroutine#1] Working in ctx2",
+ "[Ctx1 @coroutine#1] Back to ctx1"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideContext05() {
+ test("KotlinxCoroutinesExperimentalGuideContext05") { kotlinx.coroutines.experimental.guide.context05.main(emptyArray()) }.also { lines ->
+ check(lines.size == 1 && lines[0].startsWith("My job is \"coroutine#1\":BlockingCoroutine{Active}@"))
+ }
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideContext06() {
+ test("KotlinxCoroutinesExperimentalGuideContext06") { kotlinx.coroutines.experimental.guide.context06.main(emptyArray()) }.verifyLines(
+ "job1: I have my own context and execute independently!",
+ "job2: I am a child of the request coroutine",
+ "job1: I am not affected by cancellation of the request",
+ "main: Who has survived request cancellation?"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideContext07() {
+ test("KotlinxCoroutinesExperimentalGuideContext07") { kotlinx.coroutines.experimental.guide.context07.main(emptyArray()) }.verifyLines(
+ "job: I am a child of the request coroutine, but with a different dispatcher",
+ "main: Who has survived request cancellation?"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideContext08() {
+ test("KotlinxCoroutinesExperimentalGuideContext08") { kotlinx.coroutines.experimental.guide.context08.main(emptyArray()) }.verifyLines(
+ "request: I'm done and I don't explicitly join my children that are still active",
+ "Coroutine 0 is done",
+ "Coroutine 1 is done",
+ "Coroutine 2 is done",
+ "Now processing of the request is complete"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideContext09() {
+ test("KotlinxCoroutinesExperimentalGuideContext09") { kotlinx.coroutines.experimental.guide.context09.main(emptyArray()) }.verifyLinesFlexibleThread(
+ "[main @main#1] Started main coroutine",
+ "[ForkJoinPool.commonPool-worker-1 @v1coroutine#2] Computing v1",
+ "[ForkJoinPool.commonPool-worker-2 @v2coroutine#3] Computing v2",
+ "[main @main#1] The answer for v1 / v2 = 42"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideContext10() {
+ test("KotlinxCoroutinesExperimentalGuideContext10") { kotlinx.coroutines.experimental.guide.context10.main(emptyArray()) }.verifyLines(
+ "Launched 10 coroutines",
+ "Coroutine 0 is done",
+ "Coroutine 1 is done",
+ "Cancelling the job!"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideChannel01() {
+ test("KotlinxCoroutinesExperimentalGuideChannel01") { kotlinx.coroutines.experimental.guide.channel01.main(emptyArray()) }.verifyLines(
+ "1",
+ "4",
+ "9",
+ "16",
+ "25",
+ "Done!"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideChannel02() {
+ test("KotlinxCoroutinesExperimentalGuideChannel02") { kotlinx.coroutines.experimental.guide.channel02.main(emptyArray()) }.verifyLines(
+ "1",
+ "4",
+ "9",
+ "16",
+ "25",
+ "Done!"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideChannel03() {
+ test("KotlinxCoroutinesExperimentalGuideChannel03") { kotlinx.coroutines.experimental.guide.channel03.main(emptyArray()) }.verifyLines(
+ "1",
+ "4",
+ "9",
+ "16",
+ "25",
+ "Done!"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideChannel04() {
+ test("KotlinxCoroutinesExperimentalGuideChannel04") { kotlinx.coroutines.experimental.guide.channel04.main(emptyArray()) }.verifyLines(
+ "1",
+ "4",
+ "9",
+ "16",
+ "25",
+ "Done!"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideChannel05() {
+ test("KotlinxCoroutinesExperimentalGuideChannel05") { kotlinx.coroutines.experimental.guide.channel05.main(emptyArray()) }.verifyLines(
+ "2",
+ "3",
+ "5",
+ "7",
+ "11",
+ "13",
+ "17",
+ "19",
+ "23",
+ "29"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideChannel06() {
+ test("KotlinxCoroutinesExperimentalGuideChannel06") { kotlinx.coroutines.experimental.guide.channel06.main(emptyArray()) }.also { lines ->
+ check(lines.size == 10 && lines.withIndex().all { (i, line) -> line.startsWith("Processor #") && line.endsWith(" received ${i + 1}") })
+ }
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideChannel07() {
+ test("KotlinxCoroutinesExperimentalGuideChannel07") { kotlinx.coroutines.experimental.guide.channel07.main(emptyArray()) }.verifyLines(
+ "foo",
+ "foo",
+ "BAR!",
+ "foo",
+ "foo",
+ "BAR!"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideChannel08() {
+ test("KotlinxCoroutinesExperimentalGuideChannel08") { kotlinx.coroutines.experimental.guide.channel08.main(emptyArray()) }.verifyLines(
+ "Sending 0",
+ "Sending 1",
+ "Sending 2",
+ "Sending 3",
+ "Sending 4"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideChannel10() {
+ test("KotlinxCoroutinesExperimentalGuideChannel10") { kotlinx.coroutines.experimental.guide.channel10.main(emptyArray()) }.verifyLines(
+ "Initial element is available immediately: kotlin.Unit",
+ "Next element is not ready in 50 ms: null",
+ "Next element is ready in 100 ms: kotlin.Unit",
+ "Consumer pauses for 150ms",
+ "Next element is available immediately after large consumer delay: kotlin.Unit",
+ "Next element is ready in 50ms after consumer pause in 150ms: kotlin.Unit"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideChannel09() {
+ test("KotlinxCoroutinesExperimentalGuideChannel09") { kotlinx.coroutines.experimental.guide.channel09.main(emptyArray()) }.verifyLines(
+ "ping Ball(hits=1)",
+ "pong Ball(hits=2)",
+ "ping Ball(hits=3)",
+ "pong Ball(hits=4)"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideSync01() {
+ test("KotlinxCoroutinesExperimentalGuideSync01") { kotlinx.coroutines.experimental.guide.sync01.main(emptyArray()) }.verifyLinesStart(
+ "Completed 1000000 actions in",
+ "Counter ="
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideSync01b() {
+ test("KotlinxCoroutinesExperimentalGuideSync01b") { kotlinx.coroutines.experimental.guide.sync01b.main(emptyArray()) }.verifyLinesStart(
+ "Completed 1000000 actions in",
+ "Counter ="
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideSync02() {
+ test("KotlinxCoroutinesExperimentalGuideSync02") { kotlinx.coroutines.experimental.guide.sync02.main(emptyArray()) }.verifyLinesStart(
+ "Completed 1000000 actions in",
+ "Counter ="
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideSync03() {
+ test("KotlinxCoroutinesExperimentalGuideSync03") { kotlinx.coroutines.experimental.guide.sync03.main(emptyArray()) }.verifyLinesArbitraryTime(
+ "Completed 1000000 actions in xxx ms",
+ "Counter = 1000000"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideSync04() {
+ test("KotlinxCoroutinesExperimentalGuideSync04") { kotlinx.coroutines.experimental.guide.sync04.main(emptyArray()) }.verifyLinesArbitraryTime(
+ "Completed 1000000 actions in xxx ms",
+ "Counter = 1000000"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideSync05() {
+ test("KotlinxCoroutinesExperimentalGuideSync05") { kotlinx.coroutines.experimental.guide.sync05.main(emptyArray()) }.verifyLinesArbitraryTime(
+ "Completed 1000000 actions in xxx ms",
+ "Counter = 1000000"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideSync06() {
+ test("KotlinxCoroutinesExperimentalGuideSync06") { kotlinx.coroutines.experimental.guide.sync06.main(emptyArray()) }.verifyLinesArbitraryTime(
+ "Completed 1000000 actions in xxx ms",
+ "Counter = 1000000"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideSync07() {
+ test("KotlinxCoroutinesExperimentalGuideSync07") { kotlinx.coroutines.experimental.guide.sync07.main(emptyArray()) }.verifyLinesArbitraryTime(
+ "Completed 1000000 actions in xxx ms",
+ "Counter = 1000000"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideSelect01() {
+ test("KotlinxCoroutinesExperimentalGuideSelect01") { kotlinx.coroutines.experimental.guide.select01.main(emptyArray()) }.verifyLines(
+ "fizz -> 'Fizz'",
+ "buzz -> 'Buzz!'",
+ "fizz -> 'Fizz'",
+ "fizz -> 'Fizz'",
+ "buzz -> 'Buzz!'",
+ "fizz -> 'Fizz'",
+ "buzz -> 'Buzz!'"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideSelect02() {
+ test("KotlinxCoroutinesExperimentalGuideSelect02") { kotlinx.coroutines.experimental.guide.select02.main(emptyArray()) }.verifyLines(
+ "a -> 'Hello 0'",
+ "a -> 'Hello 1'",
+ "b -> 'World 0'",
+ "a -> 'Hello 2'",
+ "a -> 'Hello 3'",
+ "b -> 'World 1'",
+ "Channel 'a' is closed",
+ "Channel 'a' is closed"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideSelect03() {
+ test("KotlinxCoroutinesExperimentalGuideSelect03") { kotlinx.coroutines.experimental.guide.select03.main(emptyArray()) }.verifyLines(
+ "Consuming 1",
+ "Side channel has 2",
+ "Side channel has 3",
+ "Consuming 4",
+ "Side channel has 5",
+ "Side channel has 6",
+ "Consuming 7",
+ "Side channel has 8",
+ "Side channel has 9",
+ "Consuming 10",
+ "Done consuming"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideSelect04() {
+ test("KotlinxCoroutinesExperimentalGuideSelect04") { kotlinx.coroutines.experimental.guide.select04.main(emptyArray()) }.verifyLines(
+ "Deferred 4 produced answer 'Waited for 128 ms'",
+ "11 coroutines are still active"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalGuideSelect05() {
+ test("KotlinxCoroutinesExperimentalGuideSelect05") { kotlinx.coroutines.experimental.guide.select05.main(emptyArray()) }.verifyLines(
+ "BEGIN",
+ "Replace",
+ "END",
+ "Channel was closed"
+ )
+ }
+}
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/guide/test/TestUtil.kt b/core/kotlinx-coroutines-core/test/guide/test/TestUtil.kt
similarity index 99%
rename from core/kotlinx-coroutines-core/src/test/kotlin/guide/test/TestUtil.kt
rename to core/kotlinx-coroutines-core/test/guide/test/TestUtil.kt
index 7c93d12..89d9acd 100644
--- a/core/kotlinx-coroutines-core/src/test/kotlin/guide/test/TestUtil.kt
+++ b/core/kotlinx-coroutines-core/test/guide/test/TestUtil.kt
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package guide.test
+package kotlinx.coroutines.experimental.guide.test
import kotlinx.coroutines.experimental.*
import org.junit.Assert.assertEquals
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/internal/LockFreeLinkedListAtomicStressLFTest.kt b/core/kotlinx-coroutines-core/test/internal/LockFreeLinkedListAtomicStressLFTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/internal/LockFreeLinkedListAtomicStressLFTest.kt
rename to core/kotlinx-coroutines-core/test/internal/LockFreeLinkedListAtomicStressLFTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/internal/LockFreeLinkedListLongStressTest.kt b/core/kotlinx-coroutines-core/test/internal/LockFreeLinkedListLongStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/internal/LockFreeLinkedListLongStressTest.kt
rename to core/kotlinx-coroutines-core/test/internal/LockFreeLinkedListLongStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/internal/LockFreeLinkedListShortStressTest.kt b/core/kotlinx-coroutines-core/test/internal/LockFreeLinkedListShortStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/internal/LockFreeLinkedListShortStressTest.kt
rename to core/kotlinx-coroutines-core/test/internal/LockFreeLinkedListShortStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/internal/LockFreeLinkedListTest.kt b/core/kotlinx-coroutines-core/test/internal/LockFreeLinkedListTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/internal/LockFreeLinkedListTest.kt
rename to core/kotlinx-coroutines-core/test/internal/LockFreeLinkedListTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/internal/LockFreeListLinearizabilityTest.kt b/core/kotlinx-coroutines-core/test/internal/LockFreeListLinearizabilityTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/internal/LockFreeListLinearizabilityTest.kt
rename to core/kotlinx-coroutines-core/test/internal/LockFreeListLinearizabilityTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/internal/LockFreeMPSCQueueLinearizabilityTest.kt b/core/kotlinx-coroutines-core/test/internal/LockFreeMPSCQueueLinearizabilityTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/internal/LockFreeMPSCQueueLinearizabilityTest.kt
rename to core/kotlinx-coroutines-core/test/internal/LockFreeMPSCQueueLinearizabilityTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/internal/LockFreeMPSCQueueStressTest.kt b/core/kotlinx-coroutines-core/test/internal/LockFreeMPSCQueueStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/internal/LockFreeMPSCQueueStressTest.kt
rename to core/kotlinx-coroutines-core/test/internal/LockFreeMPSCQueueStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/internal/LockFreeMPSCQueueTest.kt b/core/kotlinx-coroutines-core/test/internal/LockFreeMPSCQueueTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/internal/LockFreeMPSCQueueTest.kt
rename to core/kotlinx-coroutines-core/test/internal/LockFreeMPSCQueueTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/internal/ThreadSafeHeapTest.kt b/core/kotlinx-coroutines-core/test/internal/ThreadSafeHeapTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/internal/ThreadSafeHeapTest.kt
rename to core/kotlinx-coroutines-core/test/internal/ThreadSafeHeapTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectChannelStressTest.kt b/core/kotlinx-coroutines-core/test/selects/SelectChannelStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectChannelStressTest.kt
rename to core/kotlinx-coroutines-core/test/selects/SelectChannelStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectMutexStressTest.kt b/core/kotlinx-coroutines-core/test/selects/SelectMutexStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectMutexStressTest.kt
rename to core/kotlinx-coroutines-core/test/selects/SelectMutexStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectPhilosophersStressTest.kt b/core/kotlinx-coroutines-core/test/selects/SelectPhilosophersStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/selects/SelectPhilosophersStressTest.kt
rename to core/kotlinx-coroutines-core/test/selects/SelectPhilosophersStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/sync/MutexStressTest.kt b/core/kotlinx-coroutines-core/test/sync/MutexStressTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/sync/MutexStressTest.kt
rename to core/kotlinx-coroutines-core/test/sync/MutexStressTest.kt
diff --git a/core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/test/TestCoroutineContextTest.kt b/core/kotlinx-coroutines-core/test/test/TestCoroutineContextTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-core/src/test/kotlin/kotlinx/coroutines/experimental/test/TestCoroutineContextTest.kt
rename to core/kotlinx-coroutines-core/test/test/TestCoroutineContextTest.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/ByteBuffer.kt b/core/kotlinx-coroutines-io/src/ByteBuffer.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/ByteBuffer.kt
rename to core/kotlinx-coroutines-io/src/ByteBuffer.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/ByteBufferChannel.kt b/core/kotlinx-coroutines-io/src/ByteBufferChannel.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/ByteBufferChannel.kt
rename to core/kotlinx-coroutines-io/src/ByteBufferChannel.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/ByteChannel.kt b/core/kotlinx-coroutines-io/src/ByteChannel.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/ByteChannel.kt
rename to core/kotlinx-coroutines-io/src/ByteChannel.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/ByteChannelCoroutine.kt b/core/kotlinx-coroutines-io/src/ByteChannelCoroutine.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/ByteChannelCoroutine.kt
rename to core/kotlinx-coroutines-io/src/ByteChannelCoroutine.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/ByteOrder.kt b/core/kotlinx-coroutines-io/src/ByteOrder.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/ByteOrder.kt
rename to core/kotlinx-coroutines-io/src/ByteOrder.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/ByteReadChannel.kt b/core/kotlinx-coroutines-io/src/ByteReadChannel.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/ByteReadChannel.kt
rename to core/kotlinx-coroutines-io/src/ByteReadChannel.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/ByteWriteChannel.kt b/core/kotlinx-coroutines-io/src/ByteWriteChannel.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/ByteWriteChannel.kt
rename to core/kotlinx-coroutines-io/src/ByteWriteChannel.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/Delimited.kt b/core/kotlinx-coroutines-io/src/Delimited.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/Delimited.kt
rename to core/kotlinx-coroutines-io/src/Delimited.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/LookAheadSession.kt b/core/kotlinx-coroutines-io/src/LookAheadSession.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/LookAheadSession.kt
rename to core/kotlinx-coroutines-io/src/LookAheadSession.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/MigrationUtils.kt b/core/kotlinx-coroutines-io/src/MigrationUtils.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/MigrationUtils.kt
rename to core/kotlinx-coroutines-io/src/MigrationUtils.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/ReaderJob.kt b/core/kotlinx-coroutines-io/src/ReaderJob.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/ReaderJob.kt
rename to core/kotlinx-coroutines-io/src/ReaderJob.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/Strings.kt b/core/kotlinx-coroutines-io/src/Strings.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/Strings.kt
rename to core/kotlinx-coroutines-io/src/Strings.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/WriterJob.kt b/core/kotlinx-coroutines-io/src/WriterJob.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/WriterJob.kt
rename to core/kotlinx-coroutines-io/src/WriterJob.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/WriterSession.kt b/core/kotlinx-coroutines-io/src/WriterSession.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/WriterSession.kt
rename to core/kotlinx-coroutines-io/src/WriterSession.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/internal/InlineRendezvousSwap.kt b/core/kotlinx-coroutines-io/src/internal/InlineRendezvousSwap.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/internal/InlineRendezvousSwap.kt
rename to core/kotlinx-coroutines-io/src/internal/InlineRendezvousSwap.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/internal/MutableDelegateContinuation.kt b/core/kotlinx-coroutines-io/src/internal/MutableDelegateContinuation.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/internal/MutableDelegateContinuation.kt
rename to core/kotlinx-coroutines-io/src/internal/MutableDelegateContinuation.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/internal/ObjectPool.kt b/core/kotlinx-coroutines-io/src/internal/ObjectPool.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/internal/ObjectPool.kt
rename to core/kotlinx-coroutines-io/src/internal/ObjectPool.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/internal/ReadWriteBufferState.kt b/core/kotlinx-coroutines-io/src/internal/ReadWriteBufferState.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/internal/ReadWriteBufferState.kt
rename to core/kotlinx-coroutines-io/src/internal/ReadWriteBufferState.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/internal/RingBufferCapacity.kt b/core/kotlinx-coroutines-io/src/internal/RingBufferCapacity.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/internal/RingBufferCapacity.kt
rename to core/kotlinx-coroutines-io/src/internal/RingBufferCapacity.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/internal/Strings.kt b/core/kotlinx-coroutines-io/src/internal/Strings.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/internal/Strings.kt
rename to core/kotlinx-coroutines-io/src/internal/Strings.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/internal/Utils.kt b/core/kotlinx-coroutines-io/src/internal/Utils.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/internal/Utils.kt
rename to core/kotlinx-coroutines-io/src/internal/Utils.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/jvm/javaio/Blocking.kt b/core/kotlinx-coroutines-io/src/jvm/javaio/Blocking.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/jvm/javaio/Blocking.kt
rename to core/kotlinx-coroutines-io/src/jvm/javaio/Blocking.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/jvm/javaio/ByteArrayPool.kt b/core/kotlinx-coroutines-io/src/jvm/javaio/ByteArrayPool.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/jvm/javaio/ByteArrayPool.kt
rename to core/kotlinx-coroutines-io/src/jvm/javaio/ByteArrayPool.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/jvm/javaio/Reading.kt b/core/kotlinx-coroutines-io/src/jvm/javaio/Reading.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/jvm/javaio/Reading.kt
rename to core/kotlinx-coroutines-io/src/jvm/javaio/Reading.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/jvm/javaio/Writing.kt b/core/kotlinx-coroutines-io/src/jvm/javaio/Writing.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/jvm/javaio/Writing.kt
rename to core/kotlinx-coroutines-io/src/jvm/javaio/Writing.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/jvm/nio/Reading.kt b/core/kotlinx-coroutines-io/src/jvm/nio/Reading.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/jvm/nio/Reading.kt
rename to core/kotlinx-coroutines-io/src/jvm/nio/Reading.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/jvm/nio/Writing.kt b/core/kotlinx-coroutines-io/src/jvm/nio/Writing.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/jvm/nio/Writing.kt
rename to core/kotlinx-coroutines-io/src/jvm/nio/Writing.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/packet/ByteReadPacket.kt b/core/kotlinx-coroutines-io/src/packet/ByteReadPacket.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/packet/ByteReadPacket.kt
rename to core/kotlinx-coroutines-io/src/packet/ByteReadPacket.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/packet/ByteReadPacketEmpty.kt b/core/kotlinx-coroutines-io/src/packet/ByteReadPacketEmpty.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/packet/ByteReadPacketEmpty.kt
rename to core/kotlinx-coroutines-io/src/packet/ByteReadPacketEmpty.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/packet/ByteWritePacketImpl.kt b/core/kotlinx-coroutines-io/src/packet/ByteWritePacketImpl.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/packet/ByteWritePacketImpl.kt
rename to core/kotlinx-coroutines-io/src/packet/ByteWritePacketImpl.kt
diff --git a/core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/packet/Packets.kt b/core/kotlinx-coroutines-io/src/packet/Packets.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/main/kotlin/kotlinx/coroutines/experimental/io/packet/Packets.kt
rename to core/kotlinx-coroutines-io/src/packet/Packets.kt
diff --git a/core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/BufferReleaseLinearizabilityTest.kt b/core/kotlinx-coroutines-io/test/BufferReleaseLinearizabilityTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/BufferReleaseLinearizabilityTest.kt
rename to core/kotlinx-coroutines-io/test/BufferReleaseLinearizabilityTest.kt
diff --git a/core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/ByteBufferChannelScenarioTest.kt b/core/kotlinx-coroutines-io/test/ByteBufferChannelScenarioTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/ByteBufferChannelScenarioTest.kt
rename to core/kotlinx-coroutines-io/test/ByteBufferChannelScenarioTest.kt
diff --git a/core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/ByteBufferChannelTest.kt b/core/kotlinx-coroutines-io/test/ByteBufferChannelTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/ByteBufferChannelTest.kt
rename to core/kotlinx-coroutines-io/test/ByteBufferChannelTest.kt
diff --git a/core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/ByteChannelCloseTest.kt b/core/kotlinx-coroutines-io/test/ByteChannelCloseTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/ByteChannelCloseTest.kt
rename to core/kotlinx-coroutines-io/test/ByteChannelCloseTest.kt
diff --git a/core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/ByteChannelJoinLinearizabilityTest.kt b/core/kotlinx-coroutines-io/test/ByteChannelJoinLinearizabilityTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/ByteChannelJoinLinearizabilityTest.kt
rename to core/kotlinx-coroutines-io/test/ByteChannelJoinLinearizabilityTest.kt
diff --git a/core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/ByteChannelJoinNoAutoFlushLinearizabilityTest.kt b/core/kotlinx-coroutines-io/test/ByteChannelJoinNoAutoFlushLinearizabilityTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/ByteChannelJoinNoAutoFlushLinearizabilityTest.kt
rename to core/kotlinx-coroutines-io/test/ByteChannelJoinNoAutoFlushLinearizabilityTest.kt
diff --git a/core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/ByteChannelLinearizabilityTest.kt b/core/kotlinx-coroutines-io/test/ByteChannelLinearizabilityTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/ByteChannelLinearizabilityTest.kt
rename to core/kotlinx-coroutines-io/test/ByteChannelLinearizabilityTest.kt
diff --git a/core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/ContentByteBufferTest.kt b/core/kotlinx-coroutines-io/test/ContentByteBufferTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/ContentByteBufferTest.kt
rename to core/kotlinx-coroutines-io/test/ContentByteBufferTest.kt
diff --git a/core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/CopyAndCloseNoAutoFlushTest.kt b/core/kotlinx-coroutines-io/test/CopyAndCloseNoAutoFlushTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/CopyAndCloseNoAutoFlushTest.kt
rename to core/kotlinx-coroutines-io/test/CopyAndCloseNoAutoFlushTest.kt
diff --git a/core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/CopyAndCloseTest.kt b/core/kotlinx-coroutines-io/test/CopyAndCloseTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/CopyAndCloseTest.kt
rename to core/kotlinx-coroutines-io/test/CopyAndCloseTest.kt
diff --git a/core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/InlineRendezvousSwapTest.kt b/core/kotlinx-coroutines-io/test/InlineRendezvousSwapTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/InlineRendezvousSwapTest.kt
rename to core/kotlinx-coroutines-io/test/InlineRendezvousSwapTest.kt
diff --git a/core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/JavaIOTest.kt b/core/kotlinx-coroutines-io/test/JavaIOTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/JavaIOTest.kt
rename to core/kotlinx-coroutines-io/test/JavaIOTest.kt
diff --git a/core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/PooledBufferTest.kt b/core/kotlinx-coroutines-io/test/PooledBufferTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/PooledBufferTest.kt
rename to core/kotlinx-coroutines-io/test/PooledBufferTest.kt
diff --git a/core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/ReadUntilDelimiterTest.kt b/core/kotlinx-coroutines-io/test/ReadUntilDelimiterTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/ReadUntilDelimiterTest.kt
rename to core/kotlinx-coroutines-io/test/ReadUntilDelimiterTest.kt
diff --git a/core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/StateMachineChecker.kt b/core/kotlinx-coroutines-io/test/StateMachineChecker.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/StateMachineChecker.kt
rename to core/kotlinx-coroutines-io/test/StateMachineChecker.kt
diff --git a/core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/StringScenarioTest.kt b/core/kotlinx-coroutines-io/test/StringScenarioTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/StringScenarioTest.kt
rename to core/kotlinx-coroutines-io/test/StringScenarioTest.kt
diff --git a/core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/StringsTest.kt b/core/kotlinx-coroutines-io/test/StringsTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/StringsTest.kt
rename to core/kotlinx-coroutines-io/test/StringsTest.kt
diff --git a/core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/VerifyingObjectPool.kt b/core/kotlinx-coroutines-io/test/VerifyingObjectPool.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/VerifyingObjectPool.kt
rename to core/kotlinx-coroutines-io/test/VerifyingObjectPool.kt
diff --git a/core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/WriteBlockLinearizabilityTest.kt b/core/kotlinx-coroutines-io/test/WriteBlockLinearizabilityTest.kt
similarity index 100%
rename from core/kotlinx-coroutines-io/src/test/kotlin/kotlinx/coroutines/experimental/io/WriteBlockLinearizabilityTest.kt
rename to core/kotlinx-coroutines-io/test/WriteBlockLinearizabilityTest.kt
diff --git a/coroutines-guide.md b/coroutines-guide.md
index 16fed7c..938f702 100644
--- a/coroutines-guide.md
+++ b/coroutines-guide.md
@@ -16,14 +16,14 @@
*/
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.$$1.example$$2
+package kotlinx.coroutines.experimental.guide.$$1$$2
import kotlinx.coroutines.experimental.*
-->
-<!--- KNIT core/kotlinx-coroutines-core/src/test/kotlin/guide/.*\.kt -->
-<!--- TEST_OUT core/kotlinx-coroutines-core/src/test/kotlin/guide/test/GuideTest.kt
+<!--- KNIT core/kotlinx-coroutines-core/test/guide/.*\.kt -->
+<!--- TEST_OUT core/kotlinx-coroutines-core/test/guide/test/GuideTest.kt
// This file was automatically generated from coroutines-guide.md by Knit tool. Do not edit.
-package guide.test
+package kotlinx.coroutines.experimental.guide.test
import org.junit.Test
@@ -127,7 +127,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-01.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-basic-01.kt)
Run this code:
@@ -171,7 +171,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-02.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-basic-02.kt)
<!--- TEST
Hello,
@@ -195,7 +195,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-02b.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-basic-02b.kt)
<!--- TEST
Hello,
@@ -234,7 +234,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-03.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-basic-03.kt)
<!--- TEST
Hello,
@@ -266,7 +266,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-04.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-basic-04.kt)
<!--- TEST
Hello,
@@ -289,7 +289,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-05.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-basic-05.kt)
<!--- TEST lines.size == 1 && lines[0] == ".".repeat(100_000) -->
@@ -313,7 +313,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-basic-06.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-basic-06.kt)
You can run and see that it prints three lines and terminates:
@@ -353,7 +353,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-01.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-cancel-01.kt)
It produces the following output:
@@ -400,7 +400,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-02.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-cancel-02.kt)
Run it to see that it continues to print "I'm sleeping" even after cancellation
until the job completes by itself after five iterations.
@@ -444,7 +444,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-03.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-cancel-03.kt)
As you can see, now this loop is cancelled. [isActive][CoroutineScope.isActive] is a property that is available inside
the code of coroutines via [CoroutineScope] object.
@@ -482,7 +482,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-04.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-cancel-04.kt)
Both [join][Job.join] and [cancelAndJoin] wait for all the finalization actions to complete,
so the example above produces the following output:
@@ -530,7 +530,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-05.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-cancel-05.kt)
<!--- TEST
I'm sleeping 0 ...
@@ -561,7 +561,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-06.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-cancel-06.kt)
It produces the following output:
@@ -597,7 +597,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-cancel-07.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-cancel-07.kt)
There is no longer an exception when running this code:
@@ -658,7 +658,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-compose-01.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-compose-01.kt)
It produces something like this:
@@ -691,7 +691,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-compose-02.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-compose-02.kt)
It produces something like this:
@@ -723,7 +723,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-compose-03.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-compose-03.kt)
It produces something like this:
@@ -780,7 +780,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-compose-04.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-compose-04.kt)
<!--- TEST ARBITRARY_TIME
The answer is 42
@@ -831,7 +831,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-01.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-context-01.kt)
It produces the following output (maybe in different order):
@@ -891,7 +891,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-02.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-context-02.kt)
Produces the output:
@@ -939,7 +939,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-03.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-context-03.kt)
There are three coroutines. The main coroutine (#1) -- `runBlocking` one,
and two coroutines computing deferred values `a` (#2) and `b` (#3).
@@ -982,7 +982,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-04.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-context-04.kt)
It demonstrates several new techniques. One is using [runBlocking] with an explicitly specified context, and
the other one is using [withContext] function to change a context of a coroutine while still staying in the
@@ -1015,7 +1015,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-05.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-context-05.kt)
It produces something like that when running in [debug mode](#debugging-coroutines-and-threads):
@@ -1069,7 +1069,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-06.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-context-06.kt)
The output of this code is:
@@ -1111,7 +1111,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-07.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-context-07.kt)
The expected outcome of this code is:
@@ -1148,7 +1148,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-08.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-context-08.kt)
The result is going to be:
@@ -1192,7 +1192,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-09.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-context-09.kt)
The output it produces with `-Dkotlinx.coroutines.debug` JVM option is similar to:
@@ -1244,7 +1244,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-context-10.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-context-10.kt)
The output of this example is:
@@ -1292,7 +1292,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-01.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-channel-01.kt)
The output of this code is:
@@ -1330,7 +1330,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-02.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-channel-02.kt)
<!--- TEST
1
@@ -1363,7 +1363,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-03.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-channel-03.kt)
<!--- TEST
1
@@ -1407,7 +1407,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-04.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-channel-04.kt)
<!--- TEST
1
@@ -1478,7 +1478,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-05.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-channel-05.kt)
The output of this code is:
@@ -1548,7 +1548,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-06.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-channel-06.kt)
The output will be similar to the the following one, albeit the processor ids that receive
each specific integer may be different:
@@ -1610,7 +1610,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-07.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-channel-07.kt)
The output is:
@@ -1656,7 +1656,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-08.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-channel-08.kt)
It prints "sending" _five_ times using a buffered channel with capacity of _four_:
@@ -1710,7 +1710,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-10.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-channel-10.kt)
It prints following lines:
@@ -1764,7 +1764,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-channel-09.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-channel-09.kt)
The "ping" coroutine is started first, so it is the first one to receive the ball. Even though "ping"
coroutine immediately starts receiving the ball again after sending it back to the table, the ball gets
@@ -1843,7 +1843,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-01.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-sync-01.kt)
<!--- TEST LINES_START
Completed 1000000 actions in
@@ -1869,7 +1869,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-01b.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-sync-01b.kt)
<!--- TEST LINES_START
Completed 1000000 actions in
@@ -1892,7 +1892,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-02.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-sync-02.kt)
<!--- TEST LINES_START
Completed 1000000 actions in
@@ -1921,7 +1921,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-03.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-sync-03.kt)
<!--- TEST ARBITRARY_TIME
Completed 1000000 actions in xxx ms
@@ -1953,7 +1953,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-04.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-sync-04.kt)
<!--- TEST ARBITRARY_TIME
Completed 1000000 actions in xxx ms
@@ -1981,7 +1981,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-05.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-sync-05.kt)
<!--- TEST ARBITRARY_TIME
Completed 1000000 actions in xxx ms
@@ -2014,7 +2014,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-06.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-sync-06.kt)
<!--- TEST ARBITRARY_TIME
Completed 1000000 actions in xxx ms
@@ -2080,7 +2080,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-sync-07.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-sync-07.kt)
<!--- TEST ARBITRARY_TIME
Completed 1000000 actions in xxx ms
@@ -2167,7 +2167,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-select-01.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-select-01.kt)
The result of this code is:
@@ -2231,7 +2231,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-select-02.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-select-02.kt)
The result of this code is quite interesting, so we'll analyze it in mode detail:
@@ -2299,7 +2299,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-select-03.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-select-03.kt)
So let us see what happens:
@@ -2366,7 +2366,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-select-04.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-select-04.kt)
The output is:
@@ -2442,7 +2442,7 @@
}
```
-> You can get full code [here](core/kotlinx-coroutines-core/src/test/kotlin/guide/example-select-05.kt)
+> You can get full code [here](core/kotlinx-coroutines-core/test/guide/example-select-05.kt)
The result of this code:
diff --git a/gradle/dokka.gradle b/gradle/dokka.gradle
index 0166263..de96307 100644
--- a/gradle/dokka.gradle
+++ b/gradle/dokka.gradle
@@ -7,7 +7,7 @@
dokka.linkMapping {
def relPath = rootProject.projectDir.toPath().relativize(projectDir.toPath())
dir = "$projectDir/src/main/kotlin"
- url = "http://github.com/kotlin/kotlinx.coroutines/tree/master/$relPath/src/main/kotlin"
+ url = "http://github.com/kotlin/kotlinx.coroutines/tree/master/$relPath/src"
suffix = "#L"
}
}
@@ -40,15 +40,15 @@
// source roots
impliedPlatforms = ['JVM', 'JS']
sourceRoot {
- path = rootProject.file("core/$project.name/src/main/kotlin")
+ path = rootProject.file("core/$project.name/src")
platforms = ['JVM']
}
sourceRoot {
- path = rootProject.file("js/$project.name-js/src/main/kotlin")
+ path = rootProject.file("js/$project.name-js/src")
platforms = ['JS']
}
sourceRoot {
- path = rootProject.file("common/$project.name-common/src/main/kotlin")
+ path = rootProject.file("common/$project.name-common/src")
}
// depends on JS & Common, too
afterEvaluate {
diff --git a/integration/kotlinx-coroutines-guava/src/main/kotlin/kotlinx/coroutines/experimental/guava/ListenableFuture.kt b/integration/kotlinx-coroutines-guava/src/ListenableFuture.kt
similarity index 100%
rename from integration/kotlinx-coroutines-guava/src/main/kotlin/kotlinx/coroutines/experimental/guava/ListenableFuture.kt
rename to integration/kotlinx-coroutines-guava/src/ListenableFuture.kt
diff --git a/integration/kotlinx-coroutines-guava/src/test/kotlin/kotlinx/coroutines/experimental/guava/ListenableFutureExceptionsTest.kt b/integration/kotlinx-coroutines-guava/test/ListenableFutureExceptionsTest.kt
similarity index 100%
rename from integration/kotlinx-coroutines-guava/src/test/kotlin/kotlinx/coroutines/experimental/guava/ListenableFutureExceptionsTest.kt
rename to integration/kotlinx-coroutines-guava/test/ListenableFutureExceptionsTest.kt
diff --git a/integration/kotlinx-coroutines-guava/src/test/kotlin/kotlinx/coroutines/experimental/guava/ListenableFutureTest.kt b/integration/kotlinx-coroutines-guava/test/ListenableFutureTest.kt
similarity index 100%
rename from integration/kotlinx-coroutines-guava/src/test/kotlin/kotlinx/coroutines/experimental/guava/ListenableFutureTest.kt
rename to integration/kotlinx-coroutines-guava/test/ListenableFutureTest.kt
diff --git a/integration/kotlinx-coroutines-jdk8/src/main/kotlin/kotlinx/coroutines/experimental/channels8/Channels.kt b/integration/kotlinx-coroutines-jdk8/src/channels8/Channels.kt
similarity index 100%
rename from integration/kotlinx-coroutines-jdk8/src/main/kotlin/kotlinx/coroutines/experimental/channels8/Channels.kt
rename to integration/kotlinx-coroutines-jdk8/src/channels8/Channels.kt
diff --git a/integration/kotlinx-coroutines-jdk8/src/main/kotlin/kotlinx/coroutines/experimental/future/Future.kt b/integration/kotlinx-coroutines-jdk8/src/future/Future.kt
similarity index 100%
rename from integration/kotlinx-coroutines-jdk8/src/main/kotlin/kotlinx/coroutines/experimental/future/Future.kt
rename to integration/kotlinx-coroutines-jdk8/src/future/Future.kt
diff --git a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/CancelFuture-example.kt b/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/CancelFuture-example.kt
deleted file mode 100644
index d80fb89..0000000
--- a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/CancelFuture-example.kt
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Copyright 2016-2017 JetBrains s.r.o.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package examples
-
-import kotlinx.coroutines.experimental.delay
-import kotlinx.coroutines.experimental.future.future
-
-fun main(args: Array<String>) {
- val f = future {
- try {
- log("Started f")
- delay(500)
- log("Slept 500 ms #1")
- delay(500)
- log("Slept 500 ms #2")
- delay(500)
- log("Slept 500 ms #3")
- delay(500)
- log("Slept 500 ms #4")
- delay(500)
- log("Slept 500 ms #5")
- } catch(e: Exception) {
- log("Aborting because of $e")
- }
- }
- Thread.sleep(1200)
- f.cancel(false)
-}
diff --git a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/ExplicitJob-example.kt b/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/ExplicitJob-example.kt
deleted file mode 100644
index fabf947..0000000
--- a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/ExplicitJob-example.kt
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Copyright 2016-2017 JetBrains s.r.o.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package examples
-
-import kotlinx.coroutines.experimental.Job
-import kotlinx.coroutines.experimental.delay
-import kotlinx.coroutines.experimental.future.future
-import java.util.concurrent.CancellationException
-
-fun main(args: Array<String>) {
- val job = Job()
- log("Starting futures f && g")
- val f = future(job) {
- log("Started f")
- delay(500)
- log("f should not execute this line")
- }
- val g = future(job) {
- log("Started g")
- try {
- delay(500)
- } finally {
- log("g is executing finally!")
- }
- log("g should not execute this line")
- }
- log("Started futures f && g... will not wait -- cancel them!!!")
- job.cancel(CancellationException("I don't want it"))
- check(f.isCancelled)
- check(g.isCancelled)
- log("f result = ${Try<Unit> { f.get() }}")
- log("g result = ${Try<Unit> { g.get() }}")
- Thread.sleep(1000L)
- log("Nothing executed!")
-}
diff --git a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/ToFuture-example.kt b/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/ToFuture-example.kt
deleted file mode 100644
index 974e1d0..0000000
--- a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/ToFuture-example.kt
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Copyright 2016-2017 JetBrains s.r.o.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package examples
-
-import kotlinx.coroutines.experimental.CommonPool
-import kotlinx.coroutines.experimental.async
-import kotlinx.coroutines.experimental.delay
-import kotlinx.coroutines.experimental.future.asCompletableFuture
-import java.util.concurrent.TimeUnit
-
-fun main(args: Array<String>) {
- log("Started")
- val deferred = async(CommonPool) {
- log("Busy...")
- delay(1, TimeUnit.SECONDS)
- log("Done...")
- 42
- }
- val future = deferred.asCompletableFuture()
- log("Got ${future.get()}")
-}
\ No newline at end of file
diff --git a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/Try.kt b/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/Try.kt
deleted file mode 100644
index 807a884..0000000
--- a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/Try.kt
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright 2016-2017 JetBrains s.r.o.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package examples
-
-public class Try<out T> private constructor(private val _value: Any?) {
- private class Fail(val exception: Throwable) {
- override fun toString(): String = "Failure[$exception]"
- }
-
- public companion object {
- public operator fun <T> invoke(block: () -> T): Try<T> =
- try { Success(block()) } catch(e: Throwable) { Failure<T>(e) }
- public fun <T> Success(value: T) = Try<T>(value)
- public fun <T> Failure(exception: Throwable) = Try<T>(Fail(exception))
- }
-
- @Suppress("UNCHECKED_CAST")
- public val value: T get() = if (_value is Fail) throw _value.exception else _value as T
-
- public val exception: Throwable? get() = (_value as? Fail)?.exception
-
- override fun toString(): String = _value.toString()
-}
diff --git a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/log.kt b/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/log.kt
deleted file mode 100644
index a875334..0000000
--- a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/log.kt
+++ /dev/null
@@ -1,22 +0,0 @@
-/*
- * Copyright 2016-2017 JetBrains s.r.o.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package examples
-
-import java.text.SimpleDateFormat
-import java.util.*
-
-fun log(msg: String) = println("${SimpleDateFormat("yyyyMMdd-HHmmss.sss").format(Date())} [${Thread.currentThread().name}] $msg")
\ No newline at end of file
diff --git a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/simple-example-1.kt b/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/simple-example-1.kt
deleted file mode 100644
index b3e0dcc..0000000
--- a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/simple-example-1.kt
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Copyright 2016-2017 JetBrains s.r.o.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package examples
-
-import kotlinx.coroutines.experimental.future.await
-import kotlinx.coroutines.experimental.runBlocking
-import java.util.concurrent.CompletableFuture
-
-fun main(args: Array<String>) {
- // Let's assume that we have a future coming from some 3rd party API
- val future: CompletableFuture<Int> = CompletableFuture.supplyAsync {
- Thread.sleep(1000L) // imitate some long-running computation, actually
- 42
- }
- // now let's launch a coroutine and await for this future inside it
- runBlocking {
- println("We can do something else, while we are waiting for future...")
- println("We've got ${future.await()} from the future!")
- }
-}
\ No newline at end of file
diff --git a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/simple-example-2.kt b/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/simple-example-2.kt
deleted file mode 100644
index 533ab6a..0000000
--- a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/simple-example-2.kt
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Copyright 2016-2017 JetBrains s.r.o.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package examples
-
-import kotlinx.coroutines.experimental.delay
-import kotlinx.coroutines.experimental.future.future
-import java.util.concurrent.CompletableFuture
-import java.util.concurrent.TimeUnit
-
-// this function returns a CompletableFuture using Kotlin coroutines
-fun supplyTheAnswerAsync(): CompletableFuture<Int> = future {
- println("We might be doing some asynchronous IO here or something else...")
- delay(1, TimeUnit.SECONDS) // just do a non-blocking delay
- 42 // The answer!
-}
-
-fun main(args: Array<String>) {
- // We can use `supplyTheAnswerAsync` just like any other future-supplier function
- val future = supplyTheAnswerAsync()
- println("The answer is ${future.get()}")
-}
\ No newline at end of file
diff --git a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/simple-example-3.kt b/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/simple-example-3.kt
deleted file mode 100644
index 734f304..0000000
--- a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/simple-example-3.kt
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Copyright 2016-2017 JetBrains s.r.o.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package examples
-
-import kotlinx.coroutines.experimental.future.await
-import kotlinx.coroutines.experimental.future.future
-import java.util.concurrent.CompletableFuture
-
-fun main(args: Array<String>) {
- // this example shows how easy it is to perform multiple async operations with coroutines
- val future = future {
- (1..5).map { // loops are no problem at all
- startLongAsyncOperation(it).await() // suspend while the long method is running
- }.joinToString("\n")
- }
- println("We have a long-running computation in background, let's wait for its result...")
- println(future.get())
-}
-
-fun startLongAsyncOperation(num: Int): CompletableFuture<String> =
- CompletableFuture.supplyAsync {
- Thread.sleep(1000L) // imitate some long-running computation, actually
- "$num" // and return a number converted to string
- }
diff --git a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/withTimeout-example.kt b/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/withTimeout-example.kt
deleted file mode 100644
index fb0d4dd..0000000
--- a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/examples/withTimeout-example.kt
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Copyright 2016-2017 JetBrains s.r.o.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package examples
-
-import kotlinx.coroutines.experimental.CancellationException
-import kotlinx.coroutines.experimental.delay
-import kotlinx.coroutines.experimental.future.await
-import kotlinx.coroutines.experimental.future.future
-import kotlinx.coroutines.experimental.withTimeout
-
-fun main(args: Array<String>) {
- fun slow(s: String) = future {
- delay(500L)
- s
- }
-
- val f = future<String> {
- log("Started f")
- val a = slow("A").await()
- log("a = $a")
- withTimeout(1000L) {
- val b = slow("B").await()
- log("b = $b")
- }
- try {
- withTimeout(750L) {
- val c = slow("C").await()
- log("c = $c")
- val d = slow("D").await()
- log("d = $d")
- }
- } catch (ex: CancellationException) {
- log("timed out with $ex")
- }
- val e = slow("E").await()
- log("e = $e")
- "done"
- }
- log("f.get() = ${f.get()}")
-}
diff --git a/integration/kotlinx-coroutines-jdk8/src/main/kotlin/kotlinx/coroutines/experimental/time/Time.kt b/integration/kotlinx-coroutines-jdk8/src/time/Time.kt
similarity index 100%
rename from integration/kotlinx-coroutines-jdk8/src/main/kotlin/kotlinx/coroutines/experimental/time/Time.kt
rename to integration/kotlinx-coroutines-jdk8/src/time/Time.kt
diff --git a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/kotlinx/coroutines/experimental/channels8/ChannelsTest.kt b/integration/kotlinx-coroutines-jdk8/test/ChannelsTest.kt
similarity index 100%
rename from integration/kotlinx-coroutines-jdk8/src/test/kotlin/kotlinx/coroutines/experimental/channels8/ChannelsTest.kt
rename to integration/kotlinx-coroutines-jdk8/test/ChannelsTest.kt
diff --git a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/kotlinx/coroutines/experimental/future/FutureExceptionsTest.kt b/integration/kotlinx-coroutines-jdk8/test/FutureExceptionsTest.kt
similarity index 100%
rename from integration/kotlinx-coroutines-jdk8/src/test/kotlin/kotlinx/coroutines/experimental/future/FutureExceptionsTest.kt
rename to integration/kotlinx-coroutines-jdk8/test/FutureExceptionsTest.kt
diff --git a/integration/kotlinx-coroutines-jdk8/src/test/kotlin/kotlinx/coroutines/experimental/future/FutureTest.kt b/integration/kotlinx-coroutines-jdk8/test/FutureTest.kt
similarity index 100%
rename from integration/kotlinx-coroutines-jdk8/src/test/kotlin/kotlinx/coroutines/experimental/future/FutureTest.kt
rename to integration/kotlinx-coroutines-jdk8/test/FutureTest.kt
diff --git a/integration/kotlinx-coroutines-nio/src/main/kotlin/kotlinx/coroutines/experimental/nio/Nio.kt b/integration/kotlinx-coroutines-nio/src/Nio.kt
similarity index 100%
rename from integration/kotlinx-coroutines-nio/src/main/kotlin/kotlinx/coroutines/experimental/nio/Nio.kt
rename to integration/kotlinx-coroutines-nio/src/Nio.kt
diff --git a/integration/kotlinx-coroutines-nio/src/test/kotlin/kotlinx/coroutines/experimental/nio/AsyncIOTest.kt b/integration/kotlinx-coroutines-nio/test/AsyncIOTest.kt
similarity index 100%
rename from integration/kotlinx-coroutines-nio/src/test/kotlin/kotlinx/coroutines/experimental/nio/AsyncIOTest.kt
rename to integration/kotlinx-coroutines-nio/test/AsyncIOTest.kt
diff --git a/integration/kotlinx-coroutines-nio/src/test/kotlin/examples/echo-example.kt b/integration/kotlinx-coroutines-nio/test/examples/echo-example.kt
similarity index 100%
rename from integration/kotlinx-coroutines-nio/src/test/kotlin/examples/echo-example.kt
rename to integration/kotlinx-coroutines-nio/test/examples/echo-example.kt
diff --git a/integration/kotlinx-coroutines-nio/src/test/kotlin/examples/log.kt b/integration/kotlinx-coroutines-nio/test/examples/log.kt
similarity index 100%
rename from integration/kotlinx-coroutines-nio/src/test/kotlin/examples/log.kt
rename to integration/kotlinx-coroutines-nio/test/examples/log.kt
diff --git a/integration/kotlinx-coroutines-quasar/src/main/kotlin/kotlinx/coroutines/experimental/quasar/KotlinSuspendableClassifier.kt b/integration/kotlinx-coroutines-quasar/src/KotlinSuspendableClassifier.kt
similarity index 100%
rename from integration/kotlinx-coroutines-quasar/src/main/kotlin/kotlinx/coroutines/experimental/quasar/KotlinSuspendableClassifier.kt
rename to integration/kotlinx-coroutines-quasar/src/KotlinSuspendableClassifier.kt
diff --git a/integration/kotlinx-coroutines-quasar/src/main/kotlin/kotlinx/coroutines/experimental/quasar/Quasar.kt b/integration/kotlinx-coroutines-quasar/src/Quasar.kt
similarity index 100%
rename from integration/kotlinx-coroutines-quasar/src/main/kotlin/kotlinx/coroutines/experimental/quasar/Quasar.kt
rename to integration/kotlinx-coroutines-quasar/src/Quasar.kt
diff --git a/integration/kotlinx-coroutines-quasar/src/main/resources/META-INF/services/co.paralleluniverse.fibers.instrument.SuspendableClassifier b/integration/kotlinx-coroutines-quasar/src/resources/META-INF/services/co.paralleluniverse.fibers.instrument.SuspendableClassifier
similarity index 100%
rename from integration/kotlinx-coroutines-quasar/src/main/resources/META-INF/services/co.paralleluniverse.fibers.instrument.SuspendableClassifier
rename to integration/kotlinx-coroutines-quasar/src/resources/META-INF/services/co.paralleluniverse.fibers.instrument.SuspendableClassifier
diff --git a/integration/kotlinx-coroutines-quasar/src/test/kotlin/kotlinx/coroutines/experimental/quasar/QuasarTest.kt b/integration/kotlinx-coroutines-quasar/test/QuasarTest.kt
similarity index 100%
rename from integration/kotlinx-coroutines-quasar/src/test/kotlin/kotlinx/coroutines/experimental/quasar/QuasarTest.kt
rename to integration/kotlinx-coroutines-quasar/test/QuasarTest.kt
diff --git a/js/example-frontend-js/src/main/kotlin/ExampleMain.kt b/js/example-frontend-js/src/ExampleMain.kt
similarity index 100%
rename from js/example-frontend-js/src/main/kotlin/ExampleMain.kt
rename to js/example-frontend-js/src/ExampleMain.kt
diff --git a/js/js-stub/src/main/kotlin/Performance.kt b/js/js-stub/src/Performance.kt
similarity index 100%
rename from js/js-stub/src/main/kotlin/Performance.kt
rename to js/js-stub/src/Performance.kt
diff --git a/js/js-stub/src/main/kotlin/Promise.kt b/js/js-stub/src/Promise.kt
similarity index 100%
rename from js/js-stub/src/main/kotlin/Promise.kt
rename to js/js-stub/src/Promise.kt
diff --git a/js/js-stub/src/main/kotlin/Window.kt b/js/js-stub/src/Window.kt
similarity index 100%
rename from js/js-stub/src/main/kotlin/Window.kt
rename to js/js-stub/src/Window.kt
diff --git a/js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/Annotations.kt b/js/kotlinx-coroutines-core-js/src/Annotations.kt
similarity index 100%
rename from js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/Annotations.kt
rename to js/kotlinx-coroutines-core-js/src/Annotations.kt
diff --git a/js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/CompletionHandler.kt b/js/kotlinx-coroutines-core-js/src/CompletionHandler.kt
similarity index 100%
rename from js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/CompletionHandler.kt
rename to js/kotlinx-coroutines-core-js/src/CompletionHandler.kt
diff --git a/js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/CoroutineContext.kt b/js/kotlinx-coroutines-core-js/src/CoroutineContext.kt
similarity index 100%
rename from js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/CoroutineContext.kt
rename to js/kotlinx-coroutines-core-js/src/CoroutineContext.kt
diff --git a/js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/CoroutineExceptionHandlerImpl.kt b/js/kotlinx-coroutines-core-js/src/CoroutineExceptionHandlerImpl.kt
similarity index 100%
rename from js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/CoroutineExceptionHandlerImpl.kt
rename to js/kotlinx-coroutines-core-js/src/CoroutineExceptionHandlerImpl.kt
diff --git a/js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/Debug.kt b/js/kotlinx-coroutines-core-js/src/Debug.kt
similarity index 100%
rename from js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/Debug.kt
rename to js/kotlinx-coroutines-core-js/src/Debug.kt
diff --git a/js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/Exceptions.kt b/js/kotlinx-coroutines-core-js/src/Exceptions.kt
similarity index 100%
rename from js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/Exceptions.kt
rename to js/kotlinx-coroutines-core-js/src/Exceptions.kt
diff --git a/js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/JSDispatcher.kt b/js/kotlinx-coroutines-core-js/src/JSDispatcher.kt
similarity index 100%
rename from js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/JSDispatcher.kt
rename to js/kotlinx-coroutines-core-js/src/JSDispatcher.kt
diff --git a/js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/Promise.kt b/js/kotlinx-coroutines-core-js/src/Promise.kt
similarity index 100%
rename from js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/Promise.kt
rename to js/kotlinx-coroutines-core-js/src/Promise.kt
diff --git a/js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/Runnable.kt b/js/kotlinx-coroutines-core-js/src/Runnable.kt
similarity index 100%
rename from js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/Runnable.kt
rename to js/kotlinx-coroutines-core-js/src/Runnable.kt
diff --git a/js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/Window.kt b/js/kotlinx-coroutines-core-js/src/Window.kt
similarity index 100%
rename from js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/Window.kt
rename to js/kotlinx-coroutines-core-js/src/Window.kt
diff --git a/js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/internal/ArrayCopy.kt b/js/kotlinx-coroutines-core-js/src/internal/ArrayCopy.kt
similarity index 100%
rename from js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/internal/ArrayCopy.kt
rename to js/kotlinx-coroutines-core-js/src/internal/ArrayCopy.kt
diff --git a/js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/internal/Closeable.kt b/js/kotlinx-coroutines-core-js/src/internal/Closeable.kt
similarity index 100%
rename from js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/internal/Closeable.kt
rename to js/kotlinx-coroutines-core-js/src/internal/Closeable.kt
diff --git a/js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/internal/Concurrent.kt b/js/kotlinx-coroutines-core-js/src/internal/Concurrent.kt
similarity index 100%
rename from js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/internal/Concurrent.kt
rename to js/kotlinx-coroutines-core-js/src/internal/Concurrent.kt
diff --git a/js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/internal/LinkedList.kt b/js/kotlinx-coroutines-core-js/src/internal/LinkedList.kt
similarity index 100%
rename from js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/internal/LinkedList.kt
rename to js/kotlinx-coroutines-core-js/src/internal/LinkedList.kt
diff --git a/js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/timeunit/TimeUnit.kt b/js/kotlinx-coroutines-core-js/src/timeunit/TimeUnit.kt
similarity index 100%
rename from js/kotlinx-coroutines-core-js/src/main/kotlin/kotlinx/coroutines/experimental/timeunit/TimeUnit.kt
rename to js/kotlinx-coroutines-core-js/src/timeunit/TimeUnit.kt
diff --git a/js/kotlinx-coroutines-core-js/src/test/kotlin/kotlinx/coroutines/experimental/MessageQueueTest.kt b/js/kotlinx-coroutines-core-js/test/MessageQueueTest.kt
similarity index 100%
rename from js/kotlinx-coroutines-core-js/src/test/kotlin/kotlinx/coroutines/experimental/MessageQueueTest.kt
rename to js/kotlinx-coroutines-core-js/test/MessageQueueTest.kt
diff --git a/js/kotlinx-coroutines-core-js/src/test/kotlin/kotlinx/coroutines/experimental/PromiseTest.kt b/js/kotlinx-coroutines-core-js/test/PromiseTest.kt
similarity index 100%
rename from js/kotlinx-coroutines-core-js/src/test/kotlin/kotlinx/coroutines/experimental/PromiseTest.kt
rename to js/kotlinx-coroutines-core-js/test/PromiseTest.kt
diff --git a/js/kotlinx-coroutines-core-js/src/test/kotlin/kotlinx/coroutines/experimental/TestBase.kt b/js/kotlinx-coroutines-core-js/test/TestBase.kt
similarity index 100%
rename from js/kotlinx-coroutines-core-js/src/test/kotlin/kotlinx/coroutines/experimental/TestBase.kt
rename to js/kotlinx-coroutines-core-js/test/TestBase.kt
diff --git a/js/kotlinx-coroutines-core-js/src/test/kotlin/kotlinx/coroutines/experimental/internal/ArrayCopyKtTest.kt b/js/kotlinx-coroutines-core-js/test/internal/ArrayCopyKtTest.kt
similarity index 100%
rename from js/kotlinx-coroutines-core-js/src/test/kotlin/kotlinx/coroutines/experimental/internal/ArrayCopyKtTest.kt
rename to js/kotlinx-coroutines-core-js/test/internal/ArrayCopyKtTest.kt
diff --git a/js/kotlinx-coroutines-core-js/src/test/kotlin/kotlinx/coroutines/experimental/internal/LinkedListTest.kt b/js/kotlinx-coroutines-core-js/test/internal/LinkedListTest.kt
similarity index 100%
rename from js/kotlinx-coroutines-core-js/src/test/kotlin/kotlinx/coroutines/experimental/internal/LinkedListTest.kt
rename to js/kotlinx-coroutines-core-js/test/internal/LinkedListTest.kt
diff --git a/license/LICENSE.txt b/license/LICENSE.txt
index 0ac9844..a4f9335 100644
--- a/license/LICENSE.txt
+++ b/license/LICENSE.txt
@@ -1,5 +1,5 @@
/*
- * Copyright 2016-2017 JetBrains s.r.o.
+ * Copyright 2016-2018 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
diff --git a/reactive/coroutines-guide-reactive.md b/reactive/coroutines-guide-reactive.md
index b19e084..a319182 100644
--- a/reactive/coroutines-guide-reactive.md
+++ b/reactive/coroutines-guide-reactive.md
@@ -16,14 +16,15 @@
*/
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.reactive.$$1.example$$2
+package kotlinx.coroutines.experimental.rx2.guide.$$1$$2
-->
-<!--- KNIT kotlinx-coroutines-rx2/src/test/kotlin/guide/.*\.kt -->
-<!--- TEST_OUT kotlinx-coroutines-rx2/src/test/kotlin/guide/test/GuideReactiveTest.kt
+<!--- KNIT kotlinx-coroutines-rx2/test/guide/.*\.kt -->
+<!--- TEST_OUT kotlinx-coroutines-rx2/test/guide/test/GuideReactiveTest.kt
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.test
+package kotlinx.coroutines.experimental.rx2.guide.test
+import kotlinx.coroutines.experimental.guide.test.*
import org.junit.Test
class GuideReactiveTest : ReactiveTestBase() {
@@ -52,7 +53,7 @@
[`kotlinx.coroutines` project](https://github.com/Kotlin/kotlinx.coroutines)
from GitHub to your workstation in order to
run all the presented examples. They are contained in
-[reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide](kotlinx-coroutines-rx2/src/test/kotlin/guide)
+[reactive/kotlinx-coroutines-rx2/test/guide](kotlinx-coroutines-rx2/test/guide)
directory of the project.
## Table of contents
@@ -127,7 +128,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-01.kt)
+> You can get full code [here](kotlinx-coroutines-rx2/test/guide/example-reactive-basic-01.kt)
This code produces the following output:
@@ -185,7 +186,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-02.kt)
+> You can get full code [here](kotlinx-coroutines-rx2/test/guide/example-reactive-basic-02.kt)
Now the output of this code changes to:
@@ -258,7 +259,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-03.kt)
+> You can get full code [here](kotlinx-coroutines-rx2/test/guide/example-reactive-basic-03.kt)
It produces the following output:
@@ -301,7 +302,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-04.kt)
+> You can get full code [here](kotlinx-coroutines-rx2/test/guide/example-reactive-basic-04.kt)
We get the following output:
@@ -372,7 +373,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-05.kt)
+> You can get full code [here](kotlinx-coroutines-rx2/test/guide/example-reactive-basic-05.kt)
The output of this code nicely illustrates how backpressure works with coroutines:
@@ -416,7 +417,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-06.kt)
+> You can get full code [here](kotlinx-coroutines-rx2/test/guide/example-reactive-basic-06.kt)
This code prints the current state of the subject on subscription and all its further updates:
@@ -453,7 +454,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-07.kt)
+> You can get full code [here](kotlinx-coroutines-rx2/test/guide/example-reactive-basic-07.kt)
The result is the same:
@@ -499,7 +500,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-08.kt)
+> You can get full code [here](kotlinx-coroutines-rx2/test/guide/example-reactive-basic-08.kt)
Now coroutine process (prints) only the most recent update:
@@ -535,7 +536,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-09.kt)
+> You can get full code [here](kotlinx-coroutines-rx2/test/guide/example-reactive-basic-09.kt)
It produces the same output as the previous example based on `BehaviorSubject`:
@@ -599,7 +600,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-operators-01.kt)
+> You can get full code [here](kotlinx-coroutines-rx2/test/guide/example-reactive-operators-01.kt)
The result of this code is quite expected:
@@ -659,7 +660,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-operators-02.kt)
+> You can get full code [here](kotlinx-coroutines-rx2/test/guide/example-reactive-operators-02.kt)
It is not hard to see, that the result is going to be:
@@ -732,7 +733,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-operators-03.kt)
+> You can get full code [here](kotlinx-coroutines-rx2/test/guide/example-reactive-operators-03.kt)
Producing
@@ -807,7 +808,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-operators-04.kt)
+> You can get full code [here](kotlinx-coroutines-rx2/test/guide/example-reactive-operators-04.kt)
And the results should be:
@@ -857,7 +858,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-context-01.kt)
+> You can get full code [here](kotlinx-coroutines-rx2/test/guide/example-reactive-context-01.kt)
We are explicitly passing the
[Schedulers.computation()](http://reactivex.io/RxJava/2.x/javadoc/io/reactivex/schedulers/Schedulers.html#computation())
@@ -899,7 +900,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-context-02.kt)
+> You can get full code [here](kotlinx-coroutines-rx2/test/guide/example-reactive-context-02.kt)
The produced output is going to be similar to:
@@ -950,7 +951,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-context-03.kt)
+> You can get full code [here](kotlinx-coroutines-rx2/test/guide/example-reactive-context-03.kt)
Here is the difference in output, notice "RxComputationThreadPool":
@@ -990,7 +991,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-context-04.kt)
+> You can get full code [here](kotlinx-coroutines-rx2/test/guide/example-reactive-context-04.kt)
The resulting messages are going to be printed in the main thread:
@@ -1038,7 +1039,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-context-05.kt)
+> You can get full code [here](kotlinx-coroutines-rx2/test/guide/example-reactive-context-05.kt)
Now, the output shows that the code of the coroutine is executing in the Rx computation thread pool, just
like our initial example using Rx `subscribe` operator.
diff --git a/reactive/kotlinx-coroutines-reactive/src/main/kotlin/kotlinx/coroutines/experimental/reactive/Await.kt b/reactive/kotlinx-coroutines-reactive/src/Await.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactive/src/main/kotlin/kotlinx/coroutines/experimental/reactive/Await.kt
rename to reactive/kotlinx-coroutines-reactive/src/Await.kt
diff --git a/reactive/kotlinx-coroutines-reactive/src/main/kotlin/kotlinx/coroutines/experimental/reactive/Channel.kt b/reactive/kotlinx-coroutines-reactive/src/Channel.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactive/src/main/kotlin/kotlinx/coroutines/experimental/reactive/Channel.kt
rename to reactive/kotlinx-coroutines-reactive/src/Channel.kt
diff --git a/reactive/kotlinx-coroutines-reactive/src/main/kotlin/kotlinx/coroutines/experimental/reactive/Convert.kt b/reactive/kotlinx-coroutines-reactive/src/Convert.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactive/src/main/kotlin/kotlinx/coroutines/experimental/reactive/Convert.kt
rename to reactive/kotlinx-coroutines-reactive/src/Convert.kt
diff --git a/reactive/kotlinx-coroutines-reactive/src/main/kotlin/kotlinx/coroutines/experimental/reactive/Publish.kt b/reactive/kotlinx-coroutines-reactive/src/Publish.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactive/src/main/kotlin/kotlinx/coroutines/experimental/reactive/Publish.kt
rename to reactive/kotlinx-coroutines-reactive/src/Publish.kt
diff --git a/reactive/kotlinx-coroutines-reactive/src/test/kotlin/kotlinx/coroutines/experimental/reactive/IntegrationTest.kt b/reactive/kotlinx-coroutines-reactive/test/IntegrationTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactive/src/test/kotlin/kotlinx/coroutines/experimental/reactive/IntegrationTest.kt
rename to reactive/kotlinx-coroutines-reactive/test/IntegrationTest.kt
diff --git a/reactive/kotlinx-coroutines-reactive/src/test/kotlin/kotlinx/coroutines/experimental/reactive/PublishTest.kt b/reactive/kotlinx-coroutines-reactive/test/PublishTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactive/src/test/kotlin/kotlinx/coroutines/experimental/reactive/PublishTest.kt
rename to reactive/kotlinx-coroutines-reactive/test/PublishTest.kt
diff --git a/reactive/kotlinx-coroutines-reactive/src/test/kotlin/kotlinx/coroutines/experimental/reactive/PublisherBackpressureTest.kt b/reactive/kotlinx-coroutines-reactive/test/PublisherBackpressureTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactive/src/test/kotlin/kotlinx/coroutines/experimental/reactive/PublisherBackpressureTest.kt
rename to reactive/kotlinx-coroutines-reactive/test/PublisherBackpressureTest.kt
diff --git a/reactive/kotlinx-coroutines-reactive/src/test/kotlin/kotlinx/coroutines/experimental/reactive/PublisherCompletionStressTest.kt b/reactive/kotlinx-coroutines-reactive/test/PublisherCompletionStressTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactive/src/test/kotlin/kotlinx/coroutines/experimental/reactive/PublisherCompletionStressTest.kt
rename to reactive/kotlinx-coroutines-reactive/test/PublisherCompletionStressTest.kt
diff --git a/reactive/kotlinx-coroutines-reactive/src/test/kotlin/kotlinx/coroutines/experimental/reactive/PublisherMultiTest.kt b/reactive/kotlinx-coroutines-reactive/test/PublisherMultiTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactive/src/test/kotlin/kotlinx/coroutines/experimental/reactive/PublisherMultiTest.kt
rename to reactive/kotlinx-coroutines-reactive/test/PublisherMultiTest.kt
diff --git a/reactive/kotlinx-coroutines-reactive/src/test/kotlin/kotlinx/coroutines/experimental/reactive/PublisherSubscriptionSelectTest.kt b/reactive/kotlinx-coroutines-reactive/test/PublisherSubscriptionSelectTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactive/src/test/kotlin/kotlinx/coroutines/experimental/reactive/PublisherSubscriptionSelectTest.kt
rename to reactive/kotlinx-coroutines-reactive/test/PublisherSubscriptionSelectTest.kt
diff --git a/reactive/kotlinx-coroutines-reactor/src/main/kotlin/kotlinx/coroutines/experimental/reactor/Convert.kt b/reactive/kotlinx-coroutines-reactor/src/Convert.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactor/src/main/kotlin/kotlinx/coroutines/experimental/reactor/Convert.kt
rename to reactive/kotlinx-coroutines-reactor/src/Convert.kt
diff --git a/reactive/kotlinx-coroutines-reactor/src/main/kotlin/kotlinx/coroutines/experimental/reactor/Flux.kt b/reactive/kotlinx-coroutines-reactor/src/Flux.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactor/src/main/kotlin/kotlinx/coroutines/experimental/reactor/Flux.kt
rename to reactive/kotlinx-coroutines-reactor/src/Flux.kt
diff --git a/reactive/kotlinx-coroutines-reactor/src/main/kotlin/kotlinx/coroutines/experimental/reactor/Mono.kt b/reactive/kotlinx-coroutines-reactor/src/Mono.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactor/src/main/kotlin/kotlinx/coroutines/experimental/reactor/Mono.kt
rename to reactive/kotlinx-coroutines-reactor/src/Mono.kt
diff --git a/reactive/kotlinx-coroutines-reactor/src/main/kotlin/kotlinx/coroutines/experimental/reactor/Scheduler.kt b/reactive/kotlinx-coroutines-reactor/src/Scheduler.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactor/src/main/kotlin/kotlinx/coroutines/experimental/reactor/Scheduler.kt
rename to reactive/kotlinx-coroutines-reactor/src/Scheduler.kt
diff --git a/reactive/kotlinx-coroutines-reactor/src/test/kotlin/kotlinx/coroutines/experimental/reactor/Check.kt b/reactive/kotlinx-coroutines-reactor/test/Check.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactor/src/test/kotlin/kotlinx/coroutines/experimental/reactor/Check.kt
rename to reactive/kotlinx-coroutines-reactor/test/Check.kt
diff --git a/reactive/kotlinx-coroutines-reactor/src/test/kotlin/kotlinx/coroutines/experimental/reactor/ConvertTest.kt b/reactive/kotlinx-coroutines-reactor/test/ConvertTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactor/src/test/kotlin/kotlinx/coroutines/experimental/reactor/ConvertTest.kt
rename to reactive/kotlinx-coroutines-reactor/test/ConvertTest.kt
diff --git a/reactive/kotlinx-coroutines-reactor/src/test/kotlin/kotlinx/coroutines/experimental/reactor/FluxCompletionStressTest.kt b/reactive/kotlinx-coroutines-reactor/test/FluxCompletionStressTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactor/src/test/kotlin/kotlinx/coroutines/experimental/reactor/FluxCompletionStressTest.kt
rename to reactive/kotlinx-coroutines-reactor/test/FluxCompletionStressTest.kt
diff --git a/reactive/kotlinx-coroutines-reactor/src/test/kotlin/kotlinx/coroutines/experimental/reactor/FluxMultiTest.kt b/reactive/kotlinx-coroutines-reactor/test/FluxMultiTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactor/src/test/kotlin/kotlinx/coroutines/experimental/reactor/FluxMultiTest.kt
rename to reactive/kotlinx-coroutines-reactor/test/FluxMultiTest.kt
diff --git a/reactive/kotlinx-coroutines-reactor/src/test/kotlin/kotlinx/coroutines/experimental/reactor/FluxSingleTest.kt b/reactive/kotlinx-coroutines-reactor/test/FluxSingleTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactor/src/test/kotlin/kotlinx/coroutines/experimental/reactor/FluxSingleTest.kt
rename to reactive/kotlinx-coroutines-reactor/test/FluxSingleTest.kt
diff --git a/reactive/kotlinx-coroutines-reactor/src/test/kotlin/kotlinx/coroutines/experimental/reactor/FluxTest.kt b/reactive/kotlinx-coroutines-reactor/test/FluxTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactor/src/test/kotlin/kotlinx/coroutines/experimental/reactor/FluxTest.kt
rename to reactive/kotlinx-coroutines-reactor/test/FluxTest.kt
diff --git a/reactive/kotlinx-coroutines-reactor/src/test/kotlin/kotlinx/coroutines/experimental/reactor/MonoTest.kt b/reactive/kotlinx-coroutines-reactor/test/MonoTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactor/src/test/kotlin/kotlinx/coroutines/experimental/reactor/MonoTest.kt
rename to reactive/kotlinx-coroutines-reactor/test/MonoTest.kt
diff --git a/reactive/kotlinx-coroutines-reactor/src/test/kotlin/kotlinx/coroutines/experimental/reactor/SchedulerTest.kt b/reactive/kotlinx-coroutines-reactor/test/SchedulerTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-reactor/src/test/kotlin/kotlinx/coroutines/experimental/reactor/SchedulerTest.kt
rename to reactive/kotlinx-coroutines-reactor/test/SchedulerTest.kt
diff --git a/reactive/kotlinx-coroutines-rx-example/src/main/kotlin/main.kt b/reactive/kotlinx-coroutines-rx-example/src/main.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx-example/src/main/kotlin/main.kt
rename to reactive/kotlinx-coroutines-rx-example/src/main.kt
diff --git a/reactive/kotlinx-coroutines-rx1/src/main/kotlin/kotlinx/coroutines/experimental/rx1/RxAwait.kt b/reactive/kotlinx-coroutines-rx1/src/RxAwait.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx1/src/main/kotlin/kotlinx/coroutines/experimental/rx1/RxAwait.kt
rename to reactive/kotlinx-coroutines-rx1/src/RxAwait.kt
diff --git a/reactive/kotlinx-coroutines-rx1/src/main/kotlin/kotlinx/coroutines/experimental/rx1/RxChannel.kt b/reactive/kotlinx-coroutines-rx1/src/RxChannel.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx1/src/main/kotlin/kotlinx/coroutines/experimental/rx1/RxChannel.kt
rename to reactive/kotlinx-coroutines-rx1/src/RxChannel.kt
diff --git a/reactive/kotlinx-coroutines-rx1/src/main/kotlin/kotlinx/coroutines/experimental/rx1/RxCompletable.kt b/reactive/kotlinx-coroutines-rx1/src/RxCompletable.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx1/src/main/kotlin/kotlinx/coroutines/experimental/rx1/RxCompletable.kt
rename to reactive/kotlinx-coroutines-rx1/src/RxCompletable.kt
diff --git a/reactive/kotlinx-coroutines-rx1/src/main/kotlin/kotlinx/coroutines/experimental/rx1/RxConvert.kt b/reactive/kotlinx-coroutines-rx1/src/RxConvert.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx1/src/main/kotlin/kotlinx/coroutines/experimental/rx1/RxConvert.kt
rename to reactive/kotlinx-coroutines-rx1/src/RxConvert.kt
diff --git a/reactive/kotlinx-coroutines-rx1/src/main/kotlin/kotlinx/coroutines/experimental/rx1/RxObservable.kt b/reactive/kotlinx-coroutines-rx1/src/RxObservable.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx1/src/main/kotlin/kotlinx/coroutines/experimental/rx1/RxObservable.kt
rename to reactive/kotlinx-coroutines-rx1/src/RxObservable.kt
diff --git a/reactive/kotlinx-coroutines-rx1/src/main/kotlin/kotlinx/coroutines/experimental/rx1/RxScheduler.kt b/reactive/kotlinx-coroutines-rx1/src/RxScheduler.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx1/src/main/kotlin/kotlinx/coroutines/experimental/rx1/RxScheduler.kt
rename to reactive/kotlinx-coroutines-rx1/src/RxScheduler.kt
diff --git a/reactive/kotlinx-coroutines-rx1/src/main/kotlin/kotlinx/coroutines/experimental/rx1/RxSingle.kt b/reactive/kotlinx-coroutines-rx1/src/RxSingle.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx1/src/main/kotlin/kotlinx/coroutines/experimental/rx1/RxSingle.kt
rename to reactive/kotlinx-coroutines-rx1/src/RxSingle.kt
diff --git a/reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/Check.kt b/reactive/kotlinx-coroutines-rx1/test/Check.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/Check.kt
rename to reactive/kotlinx-coroutines-rx1/test/Check.kt
diff --git a/reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/CompletableTest.kt b/reactive/kotlinx-coroutines-rx1/test/CompletableTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/CompletableTest.kt
rename to reactive/kotlinx-coroutines-rx1/test/CompletableTest.kt
diff --git a/reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/ConvertTest.kt b/reactive/kotlinx-coroutines-rx1/test/ConvertTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/ConvertTest.kt
rename to reactive/kotlinx-coroutines-rx1/test/ConvertTest.kt
diff --git a/reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/IntegrationTest.kt b/reactive/kotlinx-coroutines-rx1/test/IntegrationTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/IntegrationTest.kt
rename to reactive/kotlinx-coroutines-rx1/test/IntegrationTest.kt
diff --git a/reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/ObservableBackpressureTest.kt b/reactive/kotlinx-coroutines-rx1/test/ObservableBackpressureTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/ObservableBackpressureTest.kt
rename to reactive/kotlinx-coroutines-rx1/test/ObservableBackpressureTest.kt
diff --git a/reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/ObservableCompletionStressTest.kt b/reactive/kotlinx-coroutines-rx1/test/ObservableCompletionStressTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/ObservableCompletionStressTest.kt
rename to reactive/kotlinx-coroutines-rx1/test/ObservableCompletionStressTest.kt
diff --git a/reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/ObservableMultiTest.kt b/reactive/kotlinx-coroutines-rx1/test/ObservableMultiTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/ObservableMultiTest.kt
rename to reactive/kotlinx-coroutines-rx1/test/ObservableMultiTest.kt
diff --git a/reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/ObservableSingleTest.kt b/reactive/kotlinx-coroutines-rx1/test/ObservableSingleTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/ObservableSingleTest.kt
rename to reactive/kotlinx-coroutines-rx1/test/ObservableSingleTest.kt
diff --git a/reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/ObservableSubscriptionSelectTest.kt b/reactive/kotlinx-coroutines-rx1/test/ObservableSubscriptionSelectTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/ObservableSubscriptionSelectTest.kt
rename to reactive/kotlinx-coroutines-rx1/test/ObservableSubscriptionSelectTest.kt
diff --git a/reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/ObservableTest.kt b/reactive/kotlinx-coroutines-rx1/test/ObservableTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/ObservableTest.kt
rename to reactive/kotlinx-coroutines-rx1/test/ObservableTest.kt
diff --git a/reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/SchedulerTest.kt b/reactive/kotlinx-coroutines-rx1/test/SchedulerTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/SchedulerTest.kt
rename to reactive/kotlinx-coroutines-rx1/test/SchedulerTest.kt
diff --git a/reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/SingleTest.kt b/reactive/kotlinx-coroutines-rx1/test/SingleTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx1/src/test/kotlin/kotlinx/coroutines/experimental/rx1/SingleTest.kt
rename to reactive/kotlinx-coroutines-rx1/test/SingleTest.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/main/kotlin/kotlinx/coroutines/experimental/rx2/RxAwait.kt b/reactive/kotlinx-coroutines-rx2/src/RxAwait.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/main/kotlin/kotlinx/coroutines/experimental/rx2/RxAwait.kt
rename to reactive/kotlinx-coroutines-rx2/src/RxAwait.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/main/kotlin/kotlinx/coroutines/experimental/rx2/RxChannel.kt b/reactive/kotlinx-coroutines-rx2/src/RxChannel.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/main/kotlin/kotlinx/coroutines/experimental/rx2/RxChannel.kt
rename to reactive/kotlinx-coroutines-rx2/src/RxChannel.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/main/kotlin/kotlinx/coroutines/experimental/rx2/RxCompletable.kt b/reactive/kotlinx-coroutines-rx2/src/RxCompletable.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/main/kotlin/kotlinx/coroutines/experimental/rx2/RxCompletable.kt
rename to reactive/kotlinx-coroutines-rx2/src/RxCompletable.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/main/kotlin/kotlinx/coroutines/experimental/rx2/RxConvert.kt b/reactive/kotlinx-coroutines-rx2/src/RxConvert.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/main/kotlin/kotlinx/coroutines/experimental/rx2/RxConvert.kt
rename to reactive/kotlinx-coroutines-rx2/src/RxConvert.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/main/kotlin/kotlinx/coroutines/experimental/rx2/RxFlowable.kt b/reactive/kotlinx-coroutines-rx2/src/RxFlowable.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/main/kotlin/kotlinx/coroutines/experimental/rx2/RxFlowable.kt
rename to reactive/kotlinx-coroutines-rx2/src/RxFlowable.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/main/kotlin/kotlinx/coroutines/experimental/rx2/RxMaybe.kt b/reactive/kotlinx-coroutines-rx2/src/RxMaybe.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/main/kotlin/kotlinx/coroutines/experimental/rx2/RxMaybe.kt
rename to reactive/kotlinx-coroutines-rx2/src/RxMaybe.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/main/kotlin/kotlinx/coroutines/experimental/rx2/RxObservable.kt b/reactive/kotlinx-coroutines-rx2/src/RxObservable.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/main/kotlin/kotlinx/coroutines/experimental/rx2/RxObservable.kt
rename to reactive/kotlinx-coroutines-rx2/src/RxObservable.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/main/kotlin/kotlinx/coroutines/experimental/rx2/RxScheduler.kt b/reactive/kotlinx-coroutines-rx2/src/RxScheduler.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/main/kotlin/kotlinx/coroutines/experimental/rx2/RxScheduler.kt
rename to reactive/kotlinx-coroutines-rx2/src/RxScheduler.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/main/kotlin/kotlinx/coroutines/experimental/rx2/RxSingle.kt b/reactive/kotlinx-coroutines-rx2/src/RxSingle.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/main/kotlin/kotlinx/coroutines/experimental/rx2/RxSingle.kt
rename to reactive/kotlinx-coroutines-rx2/src/RxSingle.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/test/GuideReactiveTest.kt b/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/test/GuideReactiveTest.kt
deleted file mode 100644
index 254827a..0000000
--- a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/test/GuideReactiveTest.kt
+++ /dev/null
@@ -1,190 +0,0 @@
-// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.test
-
-import org.junit.Test
-
-class GuideReactiveTest : ReactiveTestBase() {
-
- @Test
- fun testGuideReactiveBasicExample01() {
- test("GuideReactiveBasicExample01") { guide.reactive.basic.example01.main(emptyArray()) }.verifyLines(
- "Elements:",
- "Begin",
- "1",
- "2",
- "3",
- "Again:"
- )
- }
-
- @Test
- fun testGuideReactiveBasicExample02() {
- test("GuideReactiveBasicExample02") { guide.reactive.basic.example02.main(emptyArray()) }.verifyLines(
- "Elements:",
- "Begin",
- "1",
- "2",
- "3",
- "Again:",
- "Begin",
- "1",
- "2",
- "3"
- )
- }
-
- @Test
- fun testGuideReactiveBasicExample03() {
- test("GuideReactiveBasicExample03") { guide.reactive.basic.example03.main(emptyArray()) }.verifyLines(
- "OnSubscribe",
- "1",
- "2",
- "3",
- "Finally"
- )
- }
-
- @Test
- fun testGuideReactiveBasicExample04() {
- test("GuideReactiveBasicExample04") { guide.reactive.basic.example04.main(emptyArray()) }.verifyLines(
- "OnSubscribe",
- "1",
- "2",
- "3",
- "4",
- "OnComplete",
- "Finally",
- "5"
- )
- }
-
- @Test
- fun testGuideReactiveBasicExample05() {
- test("GuideReactiveBasicExample05") { guide.reactive.basic.example05.main(emptyArray()) }.verifyLines(
- "Sent 1",
- "Processed 1",
- "Sent 2",
- "Processed 2",
- "Sent 3",
- "Processed 3",
- "Complete"
- )
- }
-
- @Test
- fun testGuideReactiveBasicExample06() {
- test("GuideReactiveBasicExample06") { guide.reactive.basic.example06.main(emptyArray()) }.verifyLines(
- "two",
- "three",
- "four"
- )
- }
-
- @Test
- fun testGuideReactiveBasicExample07() {
- test("GuideReactiveBasicExample07") { guide.reactive.basic.example07.main(emptyArray()) }.verifyLines(
- "two",
- "three",
- "four"
- )
- }
-
- @Test
- fun testGuideReactiveBasicExample08() {
- test("GuideReactiveBasicExample08") { guide.reactive.basic.example08.main(emptyArray()) }.verifyLines(
- "four"
- )
- }
-
- @Test
- fun testGuideReactiveBasicExample09() {
- test("GuideReactiveBasicExample09") { guide.reactive.basic.example09.main(emptyArray()) }.verifyLines(
- "four"
- )
- }
-
- @Test
- fun testGuideReactiveOperatorsExample01() {
- test("GuideReactiveOperatorsExample01") { guide.reactive.operators.example01.main(emptyArray()) }.verifyLines(
- "1",
- "2",
- "3",
- "4",
- "5"
- )
- }
-
- @Test
- fun testGuideReactiveOperatorsExample02() {
- test("GuideReactiveOperatorsExample02") { guide.reactive.operators.example02.main(emptyArray()) }.verifyLines(
- "2 is even",
- "4 is even"
- )
- }
-
- @Test
- fun testGuideReactiveOperatorsExample03() {
- test("GuideReactiveOperatorsExample03") { guide.reactive.operators.example03.main(emptyArray()) }.verifyLines(
- "1",
- "2"
- )
- }
-
- @Test
- fun testGuideReactiveOperatorsExample04() {
- test("GuideReactiveOperatorsExample04") { guide.reactive.operators.example04.main(emptyArray()) }.verifyLines(
- "1",
- "2",
- "11",
- "3",
- "4",
- "12",
- "13"
- )
- }
-
- @Test
- fun testGuideReactiveContextExample01() {
- test("GuideReactiveContextExample01") { guide.reactive.context.example01.main(emptyArray()) }.verifyLinesFlexibleThread(
- "1 on thread RxComputationThreadPool-1",
- "2 on thread RxComputationThreadPool-1",
- "3 on thread RxComputationThreadPool-1"
- )
- }
-
- @Test
- fun testGuideReactiveContextExample02() {
- test("GuideReactiveContextExample02") { guide.reactive.context.example02.main(emptyArray()) }.verifyLinesStart(
- "1 on thread ForkJoinPool.commonPool-worker-1",
- "2 on thread ForkJoinPool.commonPool-worker-1",
- "3 on thread ForkJoinPool.commonPool-worker-1"
- )
- }
-
- @Test
- fun testGuideReactiveContextExample03() {
- test("GuideReactiveContextExample03") { guide.reactive.context.example03.main(emptyArray()) }.verifyLinesFlexibleThread(
- "1 on thread RxComputationThreadPool-1",
- "2 on thread RxComputationThreadPool-1",
- "3 on thread RxComputationThreadPool-1"
- )
- }
-
- @Test
- fun testGuideReactiveContextExample04() {
- test("GuideReactiveContextExample04") { guide.reactive.context.example04.main(emptyArray()) }.verifyLinesStart(
- "1 on thread main",
- "2 on thread main",
- "3 on thread main"
- )
- }
-
- @Test
- fun testGuideReactiveContextExample05() {
- test("GuideReactiveContextExample05") { guide.reactive.context.example05.main(emptyArray()) }.verifyLinesStart(
- "1 on thread RxComputationThreadPool-1",
- "2 on thread RxComputationThreadPool-1",
- "3 on thread RxComputationThreadPool-1"
- )
- }
-}
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/Check.kt b/reactive/kotlinx-coroutines-rx2/test/Check.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/Check.kt
rename to reactive/kotlinx-coroutines-rx2/test/Check.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/CompletableTest.kt b/reactive/kotlinx-coroutines-rx2/test/CompletableTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/CompletableTest.kt
rename to reactive/kotlinx-coroutines-rx2/test/CompletableTest.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/ConvertTest.kt b/reactive/kotlinx-coroutines-rx2/test/ConvertTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/ConvertTest.kt
rename to reactive/kotlinx-coroutines-rx2/test/ConvertTest.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/FlowableTest.kt b/reactive/kotlinx-coroutines-rx2/test/FlowableTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/FlowableTest.kt
rename to reactive/kotlinx-coroutines-rx2/test/FlowableTest.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/IntegrationTest.kt b/reactive/kotlinx-coroutines-rx2/test/IntegrationTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/IntegrationTest.kt
rename to reactive/kotlinx-coroutines-rx2/test/IntegrationTest.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/MaybeTest.kt b/reactive/kotlinx-coroutines-rx2/test/MaybeTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/MaybeTest.kt
rename to reactive/kotlinx-coroutines-rx2/test/MaybeTest.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/ObservableCompletionStressTest.kt b/reactive/kotlinx-coroutines-rx2/test/ObservableCompletionStressTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/ObservableCompletionStressTest.kt
rename to reactive/kotlinx-coroutines-rx2/test/ObservableCompletionStressTest.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/ObservableMultiTest.kt b/reactive/kotlinx-coroutines-rx2/test/ObservableMultiTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/ObservableMultiTest.kt
rename to reactive/kotlinx-coroutines-rx2/test/ObservableMultiTest.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/ObservableSingleTest.kt b/reactive/kotlinx-coroutines-rx2/test/ObservableSingleTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/ObservableSingleTest.kt
rename to reactive/kotlinx-coroutines-rx2/test/ObservableSingleTest.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/ObservableSubscriptionSelectTest.kt b/reactive/kotlinx-coroutines-rx2/test/ObservableSubscriptionSelectTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/ObservableSubscriptionSelectTest.kt
rename to reactive/kotlinx-coroutines-rx2/test/ObservableSubscriptionSelectTest.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/ObservableTest.kt b/reactive/kotlinx-coroutines-rx2/test/ObservableTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/ObservableTest.kt
rename to reactive/kotlinx-coroutines-rx2/test/ObservableTest.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/SchedulerTest.kt b/reactive/kotlinx-coroutines-rx2/test/SchedulerTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/SchedulerTest.kt
rename to reactive/kotlinx-coroutines-rx2/test/SchedulerTest.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/SingleTest.kt b/reactive/kotlinx-coroutines-rx2/test/SingleTest.kt
similarity index 100%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/kotlinx/coroutines/experimental/rx2/SingleTest.kt
rename to reactive/kotlinx-coroutines-rx2/test/SingleTest.kt
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-01.kt b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-01.kt
similarity index 96%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-01.kt
rename to reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-01.kt
index 9f4f3b2..6f7f2d7 100644
--- a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-01.kt
+++ b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-01.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.reactive.basic.example01
+package kotlinx.coroutines.experimental.rx2.guide.basic01
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-02.kt b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-02.kt
similarity index 96%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-02.kt
rename to reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-02.kt
index 175fdf4..1d9bf06 100644
--- a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-02.kt
+++ b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-02.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.reactive.basic.example02
+package kotlinx.coroutines.experimental.rx2.guide.basic02
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.reactive.*
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-03.kt b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-03.kt
similarity index 96%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-03.kt
rename to reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-03.kt
index eda27b5..defe9a4 100644
--- a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-03.kt
+++ b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-03.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.reactive.basic.example03
+package kotlinx.coroutines.experimental.rx2.guide.basic03
import io.reactivex.*
import kotlinx.coroutines.experimental.*
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-04.kt b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-04.kt
similarity index 95%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-04.kt
rename to reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-04.kt
index 2d01f68..9b17b66 100644
--- a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-04.kt
+++ b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-04.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.reactive.basic.example04
+package kotlinx.coroutines.experimental.rx2.guide.basic04
import io.reactivex.*
import kotlinx.coroutines.experimental.*
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-05.kt b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-05.kt
similarity index 96%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-05.kt
rename to reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-05.kt
index 5f96bd3..e2f836f 100644
--- a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-05.kt
+++ b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-05.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.reactive.basic.example05
+package kotlinx.coroutines.experimental.rx2.guide.basic05
import io.reactivex.schedulers.*
import kotlinx.coroutines.experimental.*
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-06.kt b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-06.kt
similarity index 94%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-06.kt
rename to reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-06.kt
index eb84eaa..0b96845 100644
--- a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-06.kt
+++ b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-06.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.reactive.basic.example06
+package kotlinx.coroutines.experimental.rx2.guide.basic06
import io.reactivex.subjects.BehaviorSubject
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-07.kt b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-07.kt
similarity index 95%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-07.kt
rename to reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-07.kt
index 07b27a0..9ee5cc8 100644
--- a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-07.kt
+++ b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-07.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.reactive.basic.example07
+package kotlinx.coroutines.experimental.rx2.guide.basic07
import io.reactivex.subjects.BehaviorSubject
import kotlinx.coroutines.experimental.Unconfined
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-08.kt b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-08.kt
similarity index 95%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-08.kt
rename to reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-08.kt
index 78bcee3..41505f2 100644
--- a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-08.kt
+++ b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-08.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.reactive.basic.example08
+package kotlinx.coroutines.experimental.rx2.guide.basic08
import io.reactivex.subjects.*
import kotlinx.coroutines.experimental.*
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-09.kt b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-09.kt
similarity index 95%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-09.kt
rename to reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-09.kt
index 3b48ac2..875d279 100644
--- a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-basic-09.kt
+++ b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-basic-09.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.reactive.basic.example09
+package kotlinx.coroutines.experimental.rx2.guide.basic09
import kotlinx.coroutines.experimental.channels.*
import kotlinx.coroutines.experimental.*
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-context-01.kt b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-context-01.kt
similarity index 95%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-context-01.kt
rename to reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-context-01.kt
index 1fdeaa9..f3ea930 100644
--- a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-context-01.kt
+++ b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-context-01.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.reactive.context.example01
+package kotlinx.coroutines.experimental.rx2.guide.context01
import io.reactivex.*
import io.reactivex.functions.BiFunction
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-context-02.kt b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-context-02.kt
similarity index 95%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-context-02.kt
rename to reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-context-02.kt
index 96a62de..6332093 100644
--- a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-context-02.kt
+++ b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-context-02.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.reactive.context.example02
+package kotlinx.coroutines.experimental.rx2.guide.context02
import io.reactivex.*
import kotlinx.coroutines.experimental.*
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-context-03.kt b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-context-03.kt
similarity index 95%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-context-03.kt
rename to reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-context-03.kt
index b4b6255..a21809b 100644
--- a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-context-03.kt
+++ b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-context-03.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.reactive.context.example03
+package kotlinx.coroutines.experimental.rx2.guide.context03
import io.reactivex.*
import kotlinx.coroutines.experimental.*
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-context-04.kt b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-context-04.kt
similarity index 95%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-context-04.kt
rename to reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-context-04.kt
index 5d05940..de34e37 100644
--- a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-context-04.kt
+++ b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-context-04.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.reactive.context.example04
+package kotlinx.coroutines.experimental.rx2.guide.context04
import io.reactivex.*
import kotlinx.coroutines.experimental.*
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-context-05.kt b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-context-05.kt
similarity index 96%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-context-05.kt
rename to reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-context-05.kt
index 2d19c50..d640895 100644
--- a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-context-05.kt
+++ b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-context-05.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.reactive.context.example05
+package kotlinx.coroutines.experimental.rx2.guide.context05
import io.reactivex.*
import kotlinx.coroutines.experimental.*
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-operators-01.kt b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-operators-01.kt
similarity index 94%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-operators-01.kt
rename to reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-operators-01.kt
index cda91db..43b7b55 100644
--- a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-operators-01.kt
+++ b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-operators-01.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.reactive.operators.example01
+package kotlinx.coroutines.experimental.rx2.guide.operators01
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.reactive.*
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-operators-02.kt b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-operators-02.kt
similarity index 96%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-operators-02.kt
rename to reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-operators-02.kt
index 78cd943..518dc59 100644
--- a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-operators-02.kt
+++ b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-operators-02.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.reactive.operators.example02
+package kotlinx.coroutines.experimental.rx2.guide.operators02
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.reactive.*
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-operators-03.kt b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-operators-03.kt
similarity index 96%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-operators-03.kt
rename to reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-operators-03.kt
index cb8e262..f70834c 100644
--- a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-operators-03.kt
+++ b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-operators-03.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.reactive.operators.example03
+package kotlinx.coroutines.experimental.rx2.guide.operators03
import kotlinx.coroutines.experimental.channels.*
import kotlinx.coroutines.experimental.*
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-operators-04.kt b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-operators-04.kt
similarity index 96%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-operators-04.kt
rename to reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-operators-04.kt
index da8c1b5..46aaff4 100644
--- a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/example-reactive-operators-04.kt
+++ b/reactive/kotlinx-coroutines-rx2/test/guide/example-reactive-operators-04.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
-package guide.reactive.operators.example04
+package kotlinx.coroutines.experimental.rx2.guide.operators04
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.reactive.*
diff --git a/reactive/kotlinx-coroutines-rx2/test/guide/test/GuideReactiveTest.kt b/reactive/kotlinx-coroutines-rx2/test/guide/test/GuideReactiveTest.kt
new file mode 100644
index 0000000..d2dbd2f
--- /dev/null
+++ b/reactive/kotlinx-coroutines-rx2/test/guide/test/GuideReactiveTest.kt
@@ -0,0 +1,191 @@
+// This file was automatically generated from coroutines-guide-reactive.md by Knit tool. Do not edit.
+package kotlinx.coroutines.experimental.rx2.guide.test
+
+import kotlinx.coroutines.experimental.guide.test.*
+import org.junit.Test
+
+class GuideReactiveTest : ReactiveTestBase() {
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalRx2GuideBasic01() {
+ test("KotlinxCoroutinesExperimentalRx2GuideBasic01") { kotlinx.coroutines.experimental.rx2.guide.basic01.main(emptyArray()) }.verifyLines(
+ "Elements:",
+ "Begin",
+ "1",
+ "2",
+ "3",
+ "Again:"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalRx2GuideBasic02() {
+ test("KotlinxCoroutinesExperimentalRx2GuideBasic02") { kotlinx.coroutines.experimental.rx2.guide.basic02.main(emptyArray()) }.verifyLines(
+ "Elements:",
+ "Begin",
+ "1",
+ "2",
+ "3",
+ "Again:",
+ "Begin",
+ "1",
+ "2",
+ "3"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalRx2GuideBasic03() {
+ test("KotlinxCoroutinesExperimentalRx2GuideBasic03") { kotlinx.coroutines.experimental.rx2.guide.basic03.main(emptyArray()) }.verifyLines(
+ "OnSubscribe",
+ "1",
+ "2",
+ "3",
+ "Finally"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalRx2GuideBasic04() {
+ test("KotlinxCoroutinesExperimentalRx2GuideBasic04") { kotlinx.coroutines.experimental.rx2.guide.basic04.main(emptyArray()) }.verifyLines(
+ "OnSubscribe",
+ "1",
+ "2",
+ "3",
+ "4",
+ "OnComplete",
+ "Finally",
+ "5"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalRx2GuideBasic05() {
+ test("KotlinxCoroutinesExperimentalRx2GuideBasic05") { kotlinx.coroutines.experimental.rx2.guide.basic05.main(emptyArray()) }.verifyLines(
+ "Sent 1",
+ "Processed 1",
+ "Sent 2",
+ "Processed 2",
+ "Sent 3",
+ "Processed 3",
+ "Complete"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalRx2GuideBasic06() {
+ test("KotlinxCoroutinesExperimentalRx2GuideBasic06") { kotlinx.coroutines.experimental.rx2.guide.basic06.main(emptyArray()) }.verifyLines(
+ "two",
+ "three",
+ "four"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalRx2GuideBasic07() {
+ test("KotlinxCoroutinesExperimentalRx2GuideBasic07") { kotlinx.coroutines.experimental.rx2.guide.basic07.main(emptyArray()) }.verifyLines(
+ "two",
+ "three",
+ "four"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalRx2GuideBasic08() {
+ test("KotlinxCoroutinesExperimentalRx2GuideBasic08") { kotlinx.coroutines.experimental.rx2.guide.basic08.main(emptyArray()) }.verifyLines(
+ "four"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalRx2GuideBasic09() {
+ test("KotlinxCoroutinesExperimentalRx2GuideBasic09") { kotlinx.coroutines.experimental.rx2.guide.basic09.main(emptyArray()) }.verifyLines(
+ "four"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalRx2GuideOperators01() {
+ test("KotlinxCoroutinesExperimentalRx2GuideOperators01") { kotlinx.coroutines.experimental.rx2.guide.operators01.main(emptyArray()) }.verifyLines(
+ "1",
+ "2",
+ "3",
+ "4",
+ "5"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalRx2GuideOperators02() {
+ test("KotlinxCoroutinesExperimentalRx2GuideOperators02") { kotlinx.coroutines.experimental.rx2.guide.operators02.main(emptyArray()) }.verifyLines(
+ "2 is even",
+ "4 is even"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalRx2GuideOperators03() {
+ test("KotlinxCoroutinesExperimentalRx2GuideOperators03") { kotlinx.coroutines.experimental.rx2.guide.operators03.main(emptyArray()) }.verifyLines(
+ "1",
+ "2"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalRx2GuideOperators04() {
+ test("KotlinxCoroutinesExperimentalRx2GuideOperators04") { kotlinx.coroutines.experimental.rx2.guide.operators04.main(emptyArray()) }.verifyLines(
+ "1",
+ "2",
+ "11",
+ "3",
+ "4",
+ "12",
+ "13"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalRx2GuideContext01() {
+ test("KotlinxCoroutinesExperimentalRx2GuideContext01") { kotlinx.coroutines.experimental.rx2.guide.context01.main(emptyArray()) }.verifyLinesFlexibleThread(
+ "1 on thread RxComputationThreadPool-1",
+ "2 on thread RxComputationThreadPool-1",
+ "3 on thread RxComputationThreadPool-1"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalRx2GuideContext02() {
+ test("KotlinxCoroutinesExperimentalRx2GuideContext02") { kotlinx.coroutines.experimental.rx2.guide.context02.main(emptyArray()) }.verifyLinesStart(
+ "1 on thread ForkJoinPool.commonPool-worker-1",
+ "2 on thread ForkJoinPool.commonPool-worker-1",
+ "3 on thread ForkJoinPool.commonPool-worker-1"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalRx2GuideContext03() {
+ test("KotlinxCoroutinesExperimentalRx2GuideContext03") { kotlinx.coroutines.experimental.rx2.guide.context03.main(emptyArray()) }.verifyLinesFlexibleThread(
+ "1 on thread RxComputationThreadPool-1",
+ "2 on thread RxComputationThreadPool-1",
+ "3 on thread RxComputationThreadPool-1"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalRx2GuideContext04() {
+ test("KotlinxCoroutinesExperimentalRx2GuideContext04") { kotlinx.coroutines.experimental.rx2.guide.context04.main(emptyArray()) }.verifyLinesStart(
+ "1 on thread main",
+ "2 on thread main",
+ "3 on thread main"
+ )
+ }
+
+ @Test
+ fun testKotlinxCoroutinesExperimentalRx2GuideContext05() {
+ test("KotlinxCoroutinesExperimentalRx2GuideContext05") { kotlinx.coroutines.experimental.rx2.guide.context05.main(emptyArray()) }.verifyLinesStart(
+ "1 on thread RxComputationThreadPool-1",
+ "2 on thread RxComputationThreadPool-1",
+ "3 on thread RxComputationThreadPool-1"
+ )
+ }
+}
diff --git a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/test/ReactiveTestBase.kt b/reactive/kotlinx-coroutines-rx2/test/guide/test/ReactiveTestBase.kt
similarity index 86%
rename from reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/test/ReactiveTestBase.kt
rename to reactive/kotlinx-coroutines-rx2/test/guide/test/ReactiveTestBase.kt
index fc744ed..4992c26 100644
--- a/reactive/kotlinx-coroutines-rx2/src/test/kotlin/guide/test/ReactiveTestBase.kt
+++ b/reactive/kotlinx-coroutines-rx2/test/guide/test/ReactiveTestBase.kt
@@ -14,15 +14,15 @@
* limitations under the License.
*/
-package guide.test
+package kotlinx.coroutines.experimental.rx2.guide.test
-import io.reactivex.Scheduler
-import io.reactivex.disposables.Disposable
-import io.reactivex.plugins.RxJavaPlugins
-import kotlinx.coroutines.experimental.ignoreLostThreads
-import org.junit.After
-import org.junit.Before
-import java.util.concurrent.TimeUnit
+import io.reactivex.*
+import io.reactivex.disposables.*
+import io.reactivex.plugins.*
+import kotlinx.coroutines.experimental.*
+import kotlinx.coroutines.experimental.guide.test.*
+import org.junit.*
+import java.util.concurrent.*
open class ReactiveTestBase {
@Before
diff --git a/ui/coroutines-guide-ui.md b/ui/coroutines-guide-ui.md
index fc65aaf..f7a8376 100644
--- a/ui/coroutines-guide-ui.md
+++ b/ui/coroutines-guide-ui.md
@@ -16,7 +16,7 @@
*/
// This file was automatically generated from coroutines-guide-ui.md by Knit tool. Do not edit.
-package guide.ui.$$1.example$$2
+package kotlinx.coroutines.experimental.javafx.guide.$$1$$2
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
@@ -63,7 +63,7 @@
}
}
-->
-<!--- KNIT kotlinx-coroutines-javafx/src/test/kotlin/guide/.*\.kt -->
+<!--- KNIT kotlinx-coroutines-javafx/test/guide/.*\.kt -->
# Guide to UI programming with coroutines
@@ -133,7 +133,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-basic-01.kt)
+> You can get full code [here](kotlinx-coroutines-javafx/test/guide/example-ui-basic-01.kt)
You can clone [kotlinx.coroutines](https://github.com/Kotlin/kotlinx.coroutines) project from GitHub onto your
workstation and open the project in IDE. All the examples from this guide are in the test folder of
@@ -220,7 +220,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-basic-02.kt)
+> You can get full code [here](kotlinx-coroutines-javafx/test/guide/example-ui-basic-02.kt)
So, what happens here? Because we are launching coroutine in UI context, we can freely update UI from
inside this coroutine and invoke _suspending functions_ like [delay] at the same time. UI is not frozen
@@ -247,7 +247,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-basic-03.kt)
+> You can get full code [here](kotlinx-coroutines-javafx/test/guide/example-ui-basic-03.kt)
Now, if the circle is clicked while countdown is still running, the countdown stops.
Note, that [Job.cancel] is completely thread-safe and non-blocking. It just signals the coroutine to cancel
@@ -299,7 +299,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-actor-01.kt)
+> You can get full code [here](kotlinx-coroutines-javafx/test/guide/example-ui-actor-01.kt)
Note, that each time the circle is clicked, it starts a new coroutine and they all compete to
update the text. Try it. It does not look very good. We'll fix it later.
@@ -341,7 +341,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-actor-02.kt)
+> You can get full code [here](kotlinx-coroutines-javafx/test/guide/example-ui-actor-02.kt)
The key idea that underlies an integration of an actor coroutine and a regular event handler is that
there is an [offer][SendChannel.offer] function on [SendChannel] that does not wait. It sends an element to the actor immediately,
@@ -394,7 +394,7 @@
}
```
-> You can get full JavaFx code [here](kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-actor-03.kt).
+> You can get full JavaFx code [here](kotlinx-coroutines-javafx/test/guide/example-ui-actor-03.kt).
On Android you need to update `val eventActor = ...` line from the previous example.
Now, if a circle is clicked while the animation is running, it restarts animation after the end of it. Just once.
@@ -467,7 +467,7 @@
}
```
-> You can get full JavaFx code [here](kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-blocking-01.kt).
+> You can get full JavaFx code [here](kotlinx-coroutines-javafx/test/guide/example-ui-blocking-01.kt).
You can just copy the `fib` function and the body of the `setup` function to your Android project.
Try clicking on the circle in this example. After around 30-40th click our naive computation is going to become
@@ -509,7 +509,7 @@
}
```
-> You can get full code [here](kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-blocking-02.kt).
+> You can get full code [here](kotlinx-coroutines-javafx/test/guide/example-ui-blocking-02.kt).
You can run this code and verify that UI is not frozen while large Fibonacci numbers are being computed.
However, this code computes `fib` somewhat slower, because every recursive call to `fib` goes via `withContext`. This is
@@ -531,7 +531,7 @@
if (x <= 1) x else fibBlocking(x - 1) + fibBlocking(x - 2)
```
-> You can get full code [here](kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-blocking-03.kt).
+> You can get full code [here](kotlinx-coroutines-javafx/test/guide/example-ui-blocking-03.kt).
You can now enjoy full-speed naive Fibonacci computation without blocking the UI thread. All we need is `withContext(CommonPool)`.
@@ -641,7 +641,7 @@
}
```
-> You can get full JavaFx code [here](kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-advanced-01.kt).
+> You can get full JavaFx code [here](kotlinx-coroutines-javafx/test/guide/example-ui-advanced-01.kt).
When we start this code and click on a pinkish circle, the following messages are printed to the console:
@@ -683,7 +683,7 @@
}
```
-> You can get full JavaFx code [here](kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-advanced-02.kt).
+> You can get full JavaFx code [here](kotlinx-coroutines-javafx/test/guide/example-ui-advanced-02.kt).
It prints the following messages on click, confirming that code in the coroutine starts to execute immediately:
diff --git a/ui/kotlinx-coroutines-android/src/main/kotlin/kotlinx/coroutines/experimental/android/AndroidExceptionPreHandler.kt b/ui/kotlinx-coroutines-android/src/AndroidExceptionPreHandler.kt
similarity index 100%
rename from ui/kotlinx-coroutines-android/src/main/kotlin/kotlinx/coroutines/experimental/android/AndroidExceptionPreHandler.kt
rename to ui/kotlinx-coroutines-android/src/AndroidExceptionPreHandler.kt
diff --git a/ui/kotlinx-coroutines-android/src/main/kotlin/kotlinx/coroutines/experimental/android/HandlerContext.kt b/ui/kotlinx-coroutines-android/src/HandlerContext.kt
similarity index 100%
rename from ui/kotlinx-coroutines-android/src/main/kotlin/kotlinx/coroutines/experimental/android/HandlerContext.kt
rename to ui/kotlinx-coroutines-android/src/HandlerContext.kt
diff --git a/ui/kotlinx-coroutines-android/src/main/resources/META-INF/services/kotlinx.coroutines.experimental.CoroutineExceptionHandler b/ui/kotlinx-coroutines-android/src/resources/META-INF/services/kotlinx.coroutines.experimental.CoroutineExceptionHandler
similarity index 100%
rename from ui/kotlinx-coroutines-android/src/main/resources/META-INF/services/kotlinx.coroutines.experimental.CoroutineExceptionHandler
rename to ui/kotlinx-coroutines-android/src/resources/META-INF/services/kotlinx.coroutines.experimental.CoroutineExceptionHandler
diff --git a/ui/kotlinx-coroutines-javafx/src/main/kotlin/kotlinx/coroutines/experimental/javafx/JavaFx.kt b/ui/kotlinx-coroutines-javafx/src/JavaFx.kt
similarity index 100%
rename from ui/kotlinx-coroutines-javafx/src/main/kotlin/kotlinx/coroutines/experimental/javafx/JavaFx.kt
rename to ui/kotlinx-coroutines-javafx/src/JavaFx.kt
diff --git a/ui/kotlinx-coroutines-javafx/src/test/kotlin/kotlinx/coroutines/experimental/javafx/JavaFxTest.kt b/ui/kotlinx-coroutines-javafx/test/JavaFxTest.kt
similarity index 100%
rename from ui/kotlinx-coroutines-javafx/src/test/kotlin/kotlinx/coroutines/experimental/javafx/JavaFxTest.kt
rename to ui/kotlinx-coroutines-javafx/test/JavaFxTest.kt
diff --git a/ui/kotlinx-coroutines-javafx/src/test/kotlin/examples/FxExampleApp.kt b/ui/kotlinx-coroutines-javafx/test/examples/FxExampleApp.kt
similarity index 100%
rename from ui/kotlinx-coroutines-javafx/src/test/kotlin/examples/FxExampleApp.kt
rename to ui/kotlinx-coroutines-javafx/test/examples/FxExampleApp.kt
diff --git a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-actor-01.kt b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-actor-01.kt
similarity index 97%
rename from ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-actor-01.kt
rename to ui/kotlinx-coroutines-javafx/test/guide/example-ui-actor-01.kt
index b1def37..5050109 100644
--- a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-actor-01.kt
+++ b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-actor-01.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-ui.md by Knit tool. Do not edit.
-package guide.ui.actor.example01
+package kotlinx.coroutines.experimental.javafx.guide.actor01
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-actor-02.kt b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-actor-02.kt
similarity index 97%
rename from ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-actor-02.kt
rename to ui/kotlinx-coroutines-javafx/test/guide/example-ui-actor-02.kt
index eaa8bf9..778d6b1 100644
--- a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-actor-02.kt
+++ b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-actor-02.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-ui.md by Knit tool. Do not edit.
-package guide.ui.actor.example02
+package kotlinx.coroutines.experimental.javafx.guide.actor02
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-actor-03.kt b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-actor-03.kt
similarity index 97%
rename from ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-actor-03.kt
rename to ui/kotlinx-coroutines-javafx/test/guide/example-ui-actor-03.kt
index 9dde39f..b82e3a3 100644
--- a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-actor-03.kt
+++ b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-actor-03.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-ui.md by Knit tool. Do not edit.
-package guide.ui.actor.example03
+package kotlinx.coroutines.experimental.javafx.guide.actor03
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-advanced-01.kt b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-advanced-01.kt
similarity index 96%
rename from ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-advanced-01.kt
rename to ui/kotlinx-coroutines-javafx/test/guide/example-ui-advanced-01.kt
index dc24fe7..42597a1 100644
--- a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-advanced-01.kt
+++ b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-advanced-01.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-ui.md by Knit tool. Do not edit.
-package guide.ui.advanced.example01
+package kotlinx.coroutines.experimental.javafx.guide.advanced01
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-advanced-02.kt b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-advanced-02.kt
similarity index 97%
rename from ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-advanced-02.kt
rename to ui/kotlinx-coroutines-javafx/test/guide/example-ui-advanced-02.kt
index ef9e3b7..d065008 100644
--- a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-advanced-02.kt
+++ b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-advanced-02.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-ui.md by Knit tool. Do not edit.
-package guide.ui.advanced.example02
+package kotlinx.coroutines.experimental.javafx.guide.advanced02
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-basic-01.kt b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-basic-01.kt
similarity index 96%
rename from ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-basic-01.kt
rename to ui/kotlinx-coroutines-javafx/test/guide/example-ui-basic-01.kt
index 9072ff9..4b9a80a 100644
--- a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-basic-01.kt
+++ b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-basic-01.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-ui.md by Knit tool. Do not edit.
-package guide.ui.basic.example01
+package kotlinx.coroutines.experimental.javafx.guide.basic01
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-basic-02.kt b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-basic-02.kt
similarity index 97%
rename from ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-basic-02.kt
rename to ui/kotlinx-coroutines-javafx/test/guide/example-ui-basic-02.kt
index 63952cf..4c1c428 100644
--- a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-basic-02.kt
+++ b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-basic-02.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-ui.md by Knit tool. Do not edit.
-package guide.ui.basic.example02
+package kotlinx.coroutines.experimental.javafx.guide.basic02
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-basic-03.kt b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-basic-03.kt
similarity index 97%
rename from ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-basic-03.kt
rename to ui/kotlinx-coroutines-javafx/test/guide/example-ui-basic-03.kt
index 725b298..81ab746 100644
--- a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-basic-03.kt
+++ b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-basic-03.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-ui.md by Knit tool. Do not edit.
-package guide.ui.basic.example03
+package kotlinx.coroutines.experimental.javafx.guide.basic03
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-blocking-01.kt b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-blocking-01.kt
similarity index 97%
rename from ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-blocking-01.kt
rename to ui/kotlinx-coroutines-javafx/test/guide/example-ui-blocking-01.kt
index 61d7264..9c35c07 100644
--- a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-blocking-01.kt
+++ b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-blocking-01.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-ui.md by Knit tool. Do not edit.
-package guide.ui.blocking.example01
+package kotlinx.coroutines.experimental.javafx.guide.blocking01
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-blocking-02.kt b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-blocking-02.kt
similarity index 97%
rename from ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-blocking-02.kt
rename to ui/kotlinx-coroutines-javafx/test/guide/example-ui-blocking-02.kt
index 90f6c54..5ee6e92 100644
--- a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-blocking-02.kt
+++ b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-blocking-02.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-ui.md by Knit tool. Do not edit.
-package guide.ui.blocking.example02
+package kotlinx.coroutines.experimental.javafx.guide.blocking02
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-blocking-03.kt b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-blocking-03.kt
similarity index 97%
rename from ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-blocking-03.kt
rename to ui/kotlinx-coroutines-javafx/test/guide/example-ui-blocking-03.kt
index 68a8fae..10a1871 100644
--- a/ui/kotlinx-coroutines-javafx/src/test/kotlin/guide/example-ui-blocking-03.kt
+++ b/ui/kotlinx-coroutines-javafx/test/guide/example-ui-blocking-03.kt
@@ -15,7 +15,7 @@
*/
// This file was automatically generated from coroutines-guide-ui.md by Knit tool. Do not edit.
-package guide.ui.blocking.example03
+package kotlinx.coroutines.experimental.javafx.guide.blocking03
import kotlinx.coroutines.experimental.*
import kotlinx.coroutines.experimental.channels.*
diff --git a/ui/kotlinx-coroutines-swing/src/main/kotlin/kotlinx/coroutines/experimental/swing/Swing.kt b/ui/kotlinx-coroutines-swing/src/Swing.kt
similarity index 100%
rename from ui/kotlinx-coroutines-swing/src/main/kotlin/kotlinx/coroutines/experimental/swing/Swing.kt
rename to ui/kotlinx-coroutines-swing/src/Swing.kt
diff --git a/ui/kotlinx-coroutines-swing/src/test/kotlin/kotlinx/coroutines/experimental/swing/SwingTest.kt b/ui/kotlinx-coroutines-swing/test/SwingTest.kt
similarity index 100%
rename from ui/kotlinx-coroutines-swing/src/test/kotlin/kotlinx/coroutines/experimental/swing/SwingTest.kt
rename to ui/kotlinx-coroutines-swing/test/SwingTest.kt
diff --git a/ui/kotlinx-coroutines-swing/src/test/kotlin/examples/SwingExampleApp.kt b/ui/kotlinx-coroutines-swing/test/examples/SwingExampleApp.kt
similarity index 100%
rename from ui/kotlinx-coroutines-swing/src/test/kotlin/examples/SwingExampleApp.kt
rename to ui/kotlinx-coroutines-swing/test/examples/SwingExampleApp.kt
diff --git a/ui/kotlinx-coroutines-swing/src/test/kotlin/examples/swing-example.kt b/ui/kotlinx-coroutines-swing/test/examples/swing-example.kt
similarity index 100%
rename from ui/kotlinx-coroutines-swing/src/test/kotlin/examples/swing-example.kt
rename to ui/kotlinx-coroutines-swing/test/examples/swing-example.kt