mirror of
https://github.com/moparisthebest/curl
synced 2025-01-10 21:48:10 -05:00
ci/tests: fix escaping of testnames and disable proxy for CI APIs
Follow up toada581f
andc0d8b96
Closes #5031
This commit is contained in:
parent
e4b4ccbc67
commit
e7c144f1d1
@ -35,8 +35,11 @@ sub appveyor_check_environment {
|
|||||||
|
|
||||||
sub appveyor_create_test_result {
|
sub appveyor_create_test_result {
|
||||||
my ($testnum, $testname)=@_;
|
my ($testnum, $testname)=@_;
|
||||||
|
$testname =~ s/\\/\\\\/g;
|
||||||
|
$testname =~ s/\'/\\\'/g;
|
||||||
|
$testname =~ s/\"/\\\"/g;
|
||||||
my $appveyor_baseurl="$ENV{'APPVEYOR_API_URL'}";
|
my $appveyor_baseurl="$ENV{'APPVEYOR_API_URL'}";
|
||||||
my $appveyor_result=`curl --silent \\
|
my $appveyor_result=`curl --silent --noproxy "*" \\
|
||||||
--header "Content-Type: application/json" \\
|
--header "Content-Type: application/json" \\
|
||||||
--data "
|
--data "
|
||||||
{
|
{
|
||||||
@ -80,7 +83,7 @@ sub appveyor_update_test_result {
|
|||||||
$appveyor_category = 'Error';
|
$appveyor_category = 'Error';
|
||||||
}
|
}
|
||||||
my $appveyor_baseurl="$ENV{'APPVEYOR_API_URL'}";
|
my $appveyor_baseurl="$ENV{'APPVEYOR_API_URL'}";
|
||||||
my $appveyor_result=`curl --silent --request PUT \\
|
my $appveyor_result=`curl --silent --noproxy "*" --request PUT \\
|
||||||
--header "Content-Type: application/json" \\
|
--header "Content-Type: application/json" \\
|
||||||
--data "
|
--data "
|
||||||
{
|
{
|
||||||
@ -94,11 +97,11 @@ sub appveyor_update_test_result {
|
|||||||
"$appveyor_baseurl/api/tests"`;
|
"$appveyor_baseurl/api/tests"`;
|
||||||
print $appveyor_result;
|
print $appveyor_result;
|
||||||
if($appveyor_category eq 'Error') {
|
if($appveyor_category eq 'Error') {
|
||||||
$appveyor_result=`curl --silent \\
|
$appveyor_result=`curl --silent --noproxy "*" \\
|
||||||
--header "Content-Type: application/json" \\
|
--header "Content-Type: application/json" \\
|
||||||
--data "
|
--data "
|
||||||
{
|
{
|
||||||
'message': '$testname',
|
'message': '$testname $appveyor_outcome',
|
||||||
'category': '$appveyor_category',
|
'category': '$appveyor_category',
|
||||||
'details': 'Test $testnum $appveyor_outcome'
|
'details': 'Test $testnum $appveyor_outcome'
|
||||||
}
|
}
|
||||||
|
@ -38,7 +38,7 @@ sub azure_check_environment {
|
|||||||
|
|
||||||
sub azure_create_test_run {
|
sub azure_create_test_run {
|
||||||
my $azure_baseurl="$ENV{'SYSTEM_TEAMFOUNDATIONCOLLECTIONURI'}$ENV{'SYSTEM_TEAMPROJECTID'}";
|
my $azure_baseurl="$ENV{'SYSTEM_TEAMFOUNDATIONCOLLECTIONURI'}$ENV{'SYSTEM_TEAMPROJECTID'}";
|
||||||
my $azure_run=`curl --silent \\
|
my $azure_run=`curl --silent --noproxy "*" \\
|
||||||
--header "Authorization: Bearer $ENV{'AZURE_ACCESS_TOKEN'}" \\
|
--header "Authorization: Bearer $ENV{'AZURE_ACCESS_TOKEN'}" \\
|
||||||
--header "Content-Type: application/json" \\
|
--header "Content-Type: application/json" \\
|
||||||
--data "
|
--data "
|
||||||
@ -57,8 +57,11 @@ sub azure_create_test_run {
|
|||||||
|
|
||||||
sub azure_create_test_result {
|
sub azure_create_test_result {
|
||||||
my ($azure_run_id, $testnum, $testname)=@_;
|
my ($azure_run_id, $testnum, $testname)=@_;
|
||||||
|
$testname =~ s/\\/\\\\/g;
|
||||||
|
$testname =~ s/\'/\\\'/g;
|
||||||
|
$testname =~ s/\"/\\\"/g;
|
||||||
my $azure_baseurl="$ENV{'SYSTEM_TEAMFOUNDATIONCOLLECTIONURI'}$ENV{'SYSTEM_TEAMPROJECTID'}";
|
my $azure_baseurl="$ENV{'SYSTEM_TEAMFOUNDATIONCOLLECTIONURI'}$ENV{'SYSTEM_TEAMPROJECTID'}";
|
||||||
my $azure_result=`curl --silent \\
|
my $azure_result=`curl --silent --noproxy "*" \\
|
||||||
--header "Authorization: Bearer $ENV{'AZURE_ACCESS_TOKEN'}" \\
|
--header "Authorization: Bearer $ENV{'AZURE_ACCESS_TOKEN'}" \\
|
||||||
--header "Content-Type: application/json" \\
|
--header "Content-Type: application/json" \\
|
||||||
--data "
|
--data "
|
||||||
@ -101,7 +104,7 @@ sub azure_update_test_result {
|
|||||||
$azure_outcome = 'Failed';
|
$azure_outcome = 'Failed';
|
||||||
}
|
}
|
||||||
my $azure_baseurl="$ENV{'SYSTEM_TEAMFOUNDATIONCOLLECTIONURI'}$ENV{'SYSTEM_TEAMPROJECTID'}";
|
my $azure_baseurl="$ENV{'SYSTEM_TEAMFOUNDATIONCOLLECTIONURI'}$ENV{'SYSTEM_TEAMPROJECTID'}";
|
||||||
my $azure_result=`curl --silent --request PATCH \\
|
my $azure_result=`curl --silent --noproxy "*" --request PATCH \\
|
||||||
--header "Authorization: Bearer $ENV{'AZURE_ACCESS_TOKEN'}" \\
|
--header "Authorization: Bearer $ENV{'AZURE_ACCESS_TOKEN'}" \\
|
||||||
--header "Content-Type: application/json" \\
|
--header "Content-Type: application/json" \\
|
||||||
--data "
|
--data "
|
||||||
@ -125,7 +128,7 @@ sub azure_update_test_result {
|
|||||||
sub azure_update_test_run {
|
sub azure_update_test_run {
|
||||||
my ($azure_run_id)=@_;
|
my ($azure_run_id)=@_;
|
||||||
my $azure_baseurl="$ENV{'SYSTEM_TEAMFOUNDATIONCOLLECTIONURI'}$ENV{'SYSTEM_TEAMPROJECTID'}";
|
my $azure_baseurl="$ENV{'SYSTEM_TEAMFOUNDATIONCOLLECTIONURI'}$ENV{'SYSTEM_TEAMPROJECTID'}";
|
||||||
my $azure_run=`curl --silent --request PATCH \\
|
my $azure_run=`curl --silent --noproxy "*" --request PATCH \\
|
||||||
--header "Authorization: Bearer $ENV{'AZURE_ACCESS_TOKEN'}" \\
|
--header "Authorization: Bearer $ENV{'AZURE_ACCESS_TOKEN'}" \\
|
||||||
--header "Content-Type: application/json" \\
|
--header "Content-Type: application/json" \\
|
||||||
--data "
|
--data "
|
||||||
|
Loading…
Reference in New Issue
Block a user