]> git.argeo.org Git - gpl/argeo-slc.git/blob - legacy/org.argeo.slc.spring/ext/test/org/argeo/slc/core/execution/tasks/SystemCallTest.java
19fb1efa8d031aad56ed21ae78a029c016a76fb7
[gpl/argeo-slc.git] / legacy / org.argeo.slc.spring / ext / test / org / argeo / slc / core / execution / tasks / SystemCallTest.java
1 package org.argeo.slc.core.execution.tasks;
2
3 import org.argeo.api.cms.CmsLog;
4 import org.argeo.slc.core.execution.AbstractExecutionFlowTestCase;
5
6 public class SystemCallTest extends AbstractExecutionFlowTestCase {
7 private final static CmsLog log = CmsLog.getLog(SystemCallTest.class);
8
9 private final String defFile = "systemCall.xml";
10
11 public void testSystemCallSimple() throws Exception {
12 if (isOsSupported())
13 configureAndExecuteSlcFlow(defFile, "systemCallSimple");
14 }
15
16 public void testSystemCallList() throws Exception {
17 if (isOsSupported())
18 configureAndExecuteSlcFlow(defFile, "systemCallList");
19 }
20
21 public void testSystemCallOsSpecific() throws Exception {
22 if (isOsSupported())
23 configureAndExecuteSlcFlow(defFile, "systemCallOsSpecific");
24 }
25
26 public void testSystemCallWithVar() throws Exception {
27 if (isOsSupported())
28 configureAndExecuteSlcFlow(defFile, "systemCallWithVar");
29 }
30
31 protected boolean isOsSupported() {
32 String osName = System.getProperty("os.name");
33 final Boolean ret;
34 if (osName.contains("Windows"))
35 ret = false;
36 else
37 ret = true;
38
39 if (ret == false)
40 log.warn("Skip test because OS '" + osName + "' is not supported.");
41 return ret;
42 }
43 }