-
Notifications
You must be signed in to change notification settings - Fork 302
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adds a test suite which runs CLion headless and imports a simple project.
- Loading branch information
Showing
36 changed files
with
663 additions
and
100 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,12 @@ | ||
build --java_language_version=17 --java_runtime_version=17 | ||
|
||
# delete testdata package needed for bazel integration tests | ||
build --deleted_packages=//aspect/testing/tests/src/com/google/idea/blaze/aspect/integration/testdata | ||
query --deleted_packages=//aspect/testing/tests/src/com/google/idea/blaze/aspect/integration/testdata | ||
# Delete test data packages, needed for bazel integration tests. Update by running the following command: | ||
# bazel run @rules_bazel_integration_test//tools:update_deleted_packages | ||
build --deleted_packages=aspect/testing/tests/src/com/google/idea/blaze/aspect/integration/testdata,clwb/tests/projects/simple/main | ||
query --deleted_packages=aspect/testing/tests/src/com/google/idea/blaze/aspect/integration/testdata,clwb/tests/projects/simple/main | ||
|
||
common --enable_bzlmod | ||
|
||
# Required for CLion integration tests on windows | ||
startup --windows_enable_symlinks | ||
build --enable_runfiles |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
26 changes: 26 additions & 0 deletions
26
base/src/com/google/idea/blaze/base/sync/aspects/strategy/AspectRepositoryProvider.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
package com.google.idea.blaze.base.sync.aspects.strategy; | ||
|
||
import com.intellij.openapi.extensions.ExtensionPointName; | ||
import java.io.File; | ||
import java.util.Optional; | ||
|
||
public interface AspectRepositoryProvider { | ||
ExtensionPointName<AspectRepositoryProvider> EP_NAME = | ||
ExtensionPointName.create("com.google.idea.blaze.AspectRepositoryProvider"); | ||
|
||
String OVERRIDE_REPOSITORY_FLAG = "--override_repository=intellij_aspect"; | ||
|
||
Optional<File> aspectDirectory(); | ||
|
||
static Optional<File> findAspectDirectory() { | ||
return EP_NAME.getExtensionsIfPointIsRegistered().stream() | ||
.map(AspectRepositoryProvider::aspectDirectory) | ||
.filter(Optional::isPresent) | ||
.findFirst() | ||
.orElse(Optional.empty()); | ||
} | ||
|
||
static Optional<String> getOverrideFlag() { | ||
return findAspectDirectory().map(it -> OVERRIDE_REPOSITORY_FLAG + "=" + it.getPath()); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.