This is an automated email from the ASF dual-hosted git repository.
vladimirsitnikov pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/jmeter.git
The following commit(s) were added to refs/heads/master by this push:
new 8d629f196d test: use bin/temp/ftp_test instead of bin/ftp_test so the
generated files are not accidentally committed
8d629f196d is described below
commit 8d629f196dde05992b1ab96516711fc5ee8f44dc
Author: Vladimir Sitnikov <[email protected]>
AuthorDate: Sat Dec 30 10:11:23 2023 +0300
test: use bin/temp/ftp_test instead of bin/ftp_test so the generated files
are not accidentally committed
---
bin/testfiles/FTP_TESTS.jmx | 24 ++++++++++++------------
1 file changed, 12 insertions(+), 12 deletions(-)
diff --git a/bin/testfiles/FTP_TESTS.jmx b/bin/testfiles/FTP_TESTS.jmx
index d2ea49aed1..371a7d09c3 100644
--- a/bin/testfiles/FTP_TESTS.jmx
+++ b/bin/testfiles/FTP_TESTS.jmx
@@ -82,12 +82,12 @@ import org.apache.commons.io.FileUtils;
import org.apache.ftpserver.DataConnectionConfiguration;
import org.apache.ftpserver.DataConnectionConfigurationFactory;
-FileUtils.deleteDirectory(new File(JMeterUtils.getJMeterHome(),
"bin/ftp_test"));
-new File(JMeterUtils.getJMeterHome(), "bin/ftp_test").mkdir();
+FileUtils.deleteDirectory(new File(JMeterUtils.getJMeterHome(),
"bin/temp/ftp_test"));
+new File(JMeterUtils.getJMeterHome(), "bin/temp/ftp_test").mkdirs();
-DataConnectionConfigurationFactory dataConnectionConfigurationFactory =
+DataConnectionConfigurationFactory dataConnectionConfigurationFactory =
new DataConnectionConfigurationFactory();
-dataConnectionConfigurationFactory.setPassivePorts(vars.get("passivePort"));
+dataConnectionConfigurationFactory.setPassivePorts(vars.get("passivePort"));
DataConnectionConfiguration dataConnectionConfiguration =
dataConnectionConfigurationFactory.createDataConnectionConfiguration();
PropertiesUserManagerFactory userManagerFactory = new
PropertiesUserManagerFactory();
@@ -107,7 +107,7 @@
listenerFactory.setPort(Integer.parseInt(vars.get("port")));
FtpServerFactory factory = new FtpServerFactory();
factory.setUserManager(userManager);
factory.addListener("default", listenerFactory.createListener());
-
+
FtpServer server = factory.createServer();
server.start();
@@ -145,7 +145,7 @@ props.put("FTP_SERVER", server);
<stringProp name="FTPSampler.server"></stringProp>
<stringProp name="FTPSampler.port"></stringProp>
<stringProp name="FTPSampler.filename">jmeter.properties</stringProp>
- <stringProp
name="FTPSampler.localfilename">ftp_test/jmeter-from-ftp-binary.properties</stringProp>
+ <stringProp
name="FTPSampler.localfilename">temp/ftp_test/jmeter-from-ftp-binary.properties</stringProp>
<stringProp name="FTPSampler.inputdata"></stringProp>
<boolProp name="FTPSampler.binarymode">true</boolProp>
<boolProp name="FTPSampler.saveresponse">true</boolProp>
@@ -168,7 +168,7 @@ props.put("FTP_SERVER", server);
<stringProp name="FTPSampler.server"></stringProp>
<stringProp name="FTPSampler.port"></stringProp>
<stringProp name="FTPSampler.filename">jmeter.properties</stringProp>
- <stringProp
name="FTPSampler.localfilename">ftp_test/jmeter-from-ftp-ascii.properties</stringProp>
+ <stringProp
name="FTPSampler.localfilename">temp/ftp_test/jmeter-from-ftp-ascii.properties</stringProp>
<stringProp name="FTPSampler.inputdata"></stringProp>
<boolProp name="FTPSampler.binarymode">false</boolProp>
<boolProp name="FTPSampler.saveresponse">true</boolProp>
@@ -190,8 +190,8 @@ props.put("FTP_SERVER", server);
<FTPSampler guiclass="FtpTestSamplerGui" testclass="FTPSampler"
testname="FTP Request-put-text" enabled="true">
<stringProp name="FTPSampler.server"></stringProp>
<stringProp name="FTPSampler.port"></stringProp>
- <stringProp
name="FTPSampler.filename">ftp_test/jmeter-from-ftp-ascii-write.properties</stringProp>
- <stringProp
name="FTPSampler.localfilename">ftp_test/jmeter-from-ftp-ascii.properties</stringProp>
+ <stringProp
name="FTPSampler.filename">temp/ftp_test/jmeter-from-ftp-ascii-write.properties</stringProp>
+ <stringProp
name="FTPSampler.localfilename">temp/ftp_test/jmeter-from-ftp-ascii.properties</stringProp>
<stringProp name="FTPSampler.inputdata"></stringProp>
<boolProp name="FTPSampler.binarymode">false</boolProp>
<boolProp name="FTPSampler.saveresponse">true</boolProp>
@@ -203,8 +203,8 @@ props.put("FTP_SERVER", server);
<FTPSampler guiclass="FtpTestSamplerGui" testclass="FTPSampler"
testname="FTP Request-check-upload" enabled="true">
<stringProp name="FTPSampler.server"></stringProp>
<stringProp name="FTPSampler.port"></stringProp>
- <stringProp
name="FTPSampler.filename">ftp_test/jmeter-from-ftp-ascii-write.properties</stringProp>
- <stringProp
name="FTPSampler.localfilename">ftp_test/jmeter-from-ftp-ascii-write-tocheck.properties</stringProp>
+ <stringProp
name="FTPSampler.filename">temp/ftp_test/jmeter-from-ftp-ascii-write.properties</stringProp>
+ <stringProp
name="FTPSampler.localfilename">temp/ftp_test/jmeter-from-ftp-ascii-write-tocheck.properties</stringProp>
<stringProp name="FTPSampler.inputdata"></stringProp>
<boolProp name="FTPSampler.binarymode">false</boolProp>
<boolProp name="FTPSampler.saveresponse">true</boolProp>
@@ -248,7 +248,7 @@ import org.apache.commons.io.FileUtils;
import org.apache.commons.io.FileUtils;
-FileUtils.deleteDirectory(new File(JMeterUtils.getJMeterHome(),
"bin/ftp_test"));
+FileUtils.deleteDirectory(new File(JMeterUtils.getJMeterHome(),
"bin/temp/ftp_test"));
FtpServer server = (FtpServer) props.get("FTP_SERVER");
try {