File tree 4 files changed +9
-7
lines changed
4 files changed +9
-7
lines changed Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ sudo dpkg -i packages-microsoft-prod.deb
12
12
sudo apt-get update
13
13
sudo apt-get install apt-transport-https
14
14
sudo apt-get update
15
- sudo apt-get install dotnet-sdk-3.0 -y
15
+ sudo apt-get install dotnet-sdk-3.1 -y
16
16
17
17
# Install Python Pip and icdiff (http://www.jefftk.com/icdiff)
18
18
Original file line number Diff line number Diff line change 3
3
4
4
# Absolute paths - https://stackoverflow.com/a/246128/2105235
5
5
TESTS_DIR=$PWD /tests
6
- OUTPUT_DIR=" $TESTS_DIR /bin/Release/netcoreapp3.0 "
6
+ OUTPUT_DIR=" $TESTS_DIR /bin/Release/netcoreapp3.1 "
7
7
8
8
PHP_TMP_FILE=$OUTPUT_DIR /php.out
9
9
PEACH_TMP_FILE=$OUTPUT_DIR /peach.out
@@ -19,9 +19,8 @@ for PHP_FILE in $(find $TESTS_DIR -name *.php)
19
19
do
20
20
# Run each file in the directory it is contained in (in order for relative paths to work)
21
21
PHP_FILE_DIR=$( dirname $PHP_FILE )
22
- cd $PHP_FILE_DIR
23
22
24
- # Obtain the relative path to the PHP file so that the inclusion in Peachpie works properly
23
+ # Obtain the relative path for the log
25
24
CUT_START=$(( ${# TESTS_DIR} + 2 ))
26
25
PHP_FILE_REL=$( echo $PHP_FILE | cut -c $CUT_START -)
27
26
34
33
continue ;
35
34
fi
36
35
36
+ cd TESTS_DIR
37
+
37
38
PHP_OUTPUT=" $( php -d display_errors=Off -d log_errors=Off $PHP_FILE ) "
38
- PEACH_OUTPUT=" $( dotnet $OUTPUT_DIR /Tests.dll $PHP_FILE_REL ) "
39
+ PEACH_OUTPUT=" $( dotnet $OUTPUT_DIR /Tests.dll $PHP_FILE_DIR $PHP_FILE ) "
39
40
40
41
# .. or if either Peachpie or PHP returned a special string
41
42
if [ " $PHP_OUTPUT " = " ***SKIP***" -o " $PEACH_OUTPUT " = " ***SKIP***" ] ; then
Original file line number Diff line number Diff line change 2
2
3
3
<PropertyGroup>
4
4
<OutputType>Exe</OutputType>
5
- <TargetFramework>netcoreapp3.0 </TargetFramework>
5
+ <TargetFramework>netcoreapp3.1 </TargetFramework>
6
6
<StartupObject>program.phpx</StartupObject>
7
7
<DisableImplicitPeachpieReferences>true</DisableImplicitPeachpieReferences>
8
8
</PropertyGroup>
Original file line number Diff line number Diff line change 1
1
<?php
2
2
3
- include $argv[1];
3
+ chdir($argv[1]);
4
+ include $argv[2];
You can’t perform that action at this time.
0 commit comments