All Downloads are FREE. Search and download functionalities are using the official Maven repository.

main.name.remal.gradle_plugins.plugins.testing.RandomizeTestClassesExtension.kt Maven / Gradle / Ivy

There is a newer version: 1.9.2
Show newest version
package name.remal.gradle_plugins.plugins.testing

import name.remal.gradle_plugins.dsl.Extension
import org.gradle.api.Project
import java.lang.Math.abs
import java.lang.System.currentTimeMillis
import java.lang.System.identityHashCode

@Extension
class RandomizeTestClassesExtension(private val project: Project) {

    companion object {
        private val seedAddition = currentTimeMillis() / 1000
    }

    var enabled: Boolean = true

    var seed: Long = abs(seedAddition - identityHashCode(project.rootProject).toLong() - identityHashCode(project.rootProject.gradle).toLong())

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy