Skip to content

Commit

Permalink
Refactoring with test file exemption removal
Browse files Browse the repository at this point in the history
Would probably need to fix failing test cases first to actually see coverage workflows in action, will switch to PR 2.2
  • Loading branch information
Rd4dev committed Aug 8, 2024
1 parent 30f3e97 commit e527dd9
Show file tree
Hide file tree
Showing 5 changed files with 1 addition and 13 deletions.
1 change: 0 additions & 1 deletion scripts/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,6 @@ kt_jvm_binary(
kt_jvm_binary(
name = "compute_changed_files",
testonly = True,
data = TEST_FILE_EXEMPTION_ASSETS,
main_class = "org.oppia.android.scripts.ci.ComputeChangedFilesKt",
runtime_deps = ["//scripts/src/java/org/oppia/android/scripts/ci:compute_changed_files_lib"],
)
Expand Down
1 change: 0 additions & 1 deletion scripts/src/java/org/oppia/android/scripts/ci/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@ kt_jvm_library(
"//scripts/src/java/org/oppia/android/scripts/common:proto_string_encoder",
"//scripts/src/java/org/oppia/android/scripts/common:repository_file",
"//scripts/src/java/org/oppia/android/scripts/proto:changed_files_java_proto",
"//scripts/src/java/org/oppia/android/scripts/proto:script_exemptions_java_proto",
],
)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import org.oppia.android.scripts.common.ProtoStringEncoder.Companion.toCompresse
import org.oppia.android.scripts.common.RepositoryFile
import org.oppia.android.scripts.common.ScriptBackgroundCoroutineDispatcher
import org.oppia.android.scripts.proto.ChangedFilesBucket
import org.oppia.android.scripts.proto.TestFileExemptions
import java.io.File
import java.util.Locale
import java.util.concurrent.TimeUnit
Expand Down Expand Up @@ -313,11 +312,3 @@ class ComputeChangedFiles(
SMALL_PARTITIONS
}
}

private fun loadTestFileExemptionsProto(testFileExemptiontextProto: String): TestFileExemptions {
return File("$testFileExemptiontextProto.pb").inputStream().use { stream ->
TestFileExemptions.newBuilder().also { builder ->
builder.mergeFrom(stream)
}.build()
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ kt_jvm_test(
name = "ComputeChangedFilesTest",
size = "large",
srcs = ["ComputeChangedFilesTest.kt"],
# shard_count = 24,
deps = [
"//scripts/src/java/org/oppia/android/scripts/ci:compute_changed_files_lib",
"//scripts/src/java/org/oppia/android/scripts/common:proto_string_encoder",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -223,4 +223,4 @@ class RetrieveChangedFilesTest {
scriptBgDispatcher, processTimeout = 5, processTimeoutUnit = TimeUnit.MINUTES
)
}
}
}

0 comments on commit e527dd9

Please sign in to comment.