diff options
author | LogicFan <38597904+LogicFan@users.noreply.github.com> | 2021-05-22 18:28:42 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-22 23:28:42 +0100 |
commit | e955ebb8c56378b166adbd440f237999a346099e (patch) | |
tree | 7effc5bfb093afdfceafb3410ae5de2f19417436 /src/test/groovy/net | |
parent | de665ab4989bceb4ff323ebc0851ef781a0ef5de (diff) | |
download | architectury-loom-e955ebb8c56378b166adbd440f237999a346099e.tar.gz architectury-loom-e955ebb8c56378b166adbd440f237999a346099e.tar.bz2 architectury-loom-e955ebb8c56378b166adbd440f237999a346099e.zip |
add support for new dependencyResolutionManagement (#400)
* move repo declartions
- Move repository declartions in MavenConfiguration.java to LoomRepositoryPlugin.java
* move repo declartions
- Move repository declartions in MinecraftMappedProvider.java to LoomRepositoryPlugin.java
* move repo declartions
- Move repository declarations in MinecraftProcessedProvider.java to LoomRepositoryPlugin.java
* do not add repositories if dependencyResolutionManagement is used
* Simplify the change on LoomGradlePlugin
- this is the suggestion from liach
* change name to follow fabric naming convension
- change getProjectUUID to getProjectUuid
- change PROJECT_MAPPED_CLASSIFIER to projectMappedClassifier
* remove MavenConfiguration.java
- the file currently do nothing.
* clean-up for all `instanceof` clause
* add DependencyResolutionManagementTest
* code cleanup
* Update src/test/resources/projects/dependencyResolutionManagement/projmap/src/main/resources/modid.accesswidener
* change project uuid to project full name
Co-authored-by: modmuss50 <modmuss50@gmail.com>
Diffstat (limited to 'src/test/groovy/net')
-rw-r--r-- | src/test/groovy/net/fabricmc/loom/test/integration/dependencyResolutionManagement.groovy | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/src/test/groovy/net/fabricmc/loom/test/integration/dependencyResolutionManagement.groovy b/src/test/groovy/net/fabricmc/loom/test/integration/dependencyResolutionManagement.groovy new file mode 100644 index 00000000..a8b27336 --- /dev/null +++ b/src/test/groovy/net/fabricmc/loom/test/integration/dependencyResolutionManagement.groovy @@ -0,0 +1,52 @@ +/* + * This file is part of fabric-loom, licensed under the MIT License (MIT). + * + * Copyright (c) 2016, 2017, 2018 FabricMC + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + */ + +package net.fabricmc.loom.test.integration + +import net.fabricmc.loom.test.util.ProjectTestTrait +import spock.lang.Specification +import spock.lang.Unroll + +import static org.gradle.testkit.runner.TaskOutcome.SUCCESS + +class DependencyResolutionManagementTest extends Specification implements ProjectTestTrait { + @Override + String name() { + "dependencyResolutionManagement" + } + + @Unroll + def "build (gradle #gradle)"() { + when: + def result = create("build", gradle) + then: + result.task(":basic:build").outcome == SUCCESS + result.task(":projmap:build").outcome == SUCCESS + + where: + gradle | _ + DEFAULT_GRADLE | _ + PRE_RELEASE_GRADLE | _ + } +} |