You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by gg...@apache.org on 2025/11/25 12:28:36 UTC
(commons-exec) 02/04: Merge ifs with the same return value
This is an automated email from the ASF dual-hosted git repository.
ggregory pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-exec.git
commit 11a38d49a852ff4f73ebf489d694a9c5b5d18d04
Author: Gary Gregory <ga...@gmail.com>
AuthorDate: Tue Nov 25 07:23:42 2025 -0500
Merge ifs with the same return value
---
src/test/java/org/apache/commons/exec/TestUtil.java | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/src/test/java/org/apache/commons/exec/TestUtil.java b/src/test/java/org/apache/commons/exec/TestUtil.java
index 4e3b5fc3..4166b786 100644
--- a/src/test/java/org/apache/commons/exec/TestUtil.java
+++ b/src/test/java/org/apache/commons/exec/TestUtil.java
@@ -35,10 +35,7 @@ public final class TestUtil {
* @return int array[2] = {ok, success}
*/
public static int[] getTestScriptCodesForOS() {
- if (OS.isFamilyWindows()) {
- return new int[] { 0, 1 };
- }
- if (OS.isFamilyUnix()) {
+ if (OS.isFamilyWindows() || OS.isFamilyUnix()) {
return new int[] { 0, 1 };
}
if (OS.isFamilyOpenVms()) {