Re: [PATCH v2 00/13] Offer to run CI/PR builds in Azure Pipelines

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Junio,

On Thu, 17 Jan 2019, Junio C Hamano wrote:

> Johannes Schindelin <Johannes.Schindelin@xxxxxx> writes:
> 
> > ...
> > See the updated series:
> > https://public-inbox.org/git/pull.31.v3.git.gitgitgadget@xxxxxxxxx/
> 
> Thanks.
> 
> I see that you are already planning for v4, but I'll find time to
> take a look at what is posted sometime this week anyway.

Yes, v4 will ideally have only cosmetic changes apart from the
part that fixes the traces of the published failed tests:

-- snipsnap --
15:  f678b105f81e ! 15:  7b74987d72a6 tests: include detailed trace logs with --write-junit-xml upon failure
    @@ -32,6 +32,38 @@
     
         Signed-off-by: Johannes Schindelin <johannes.schindelin@xxxxxx>
     
    + diff --git a/t/helper/test-path-utils.c b/t/helper/test-path-utils.c
    + --- a/t/helper/test-path-utils.c
    + +++ b/t/helper/test-path-utils.c
    +@@
    + 		return !!res;
    + 	}
    + 
    ++	if (argc == 4 && !strcmp(argv[1], "skip-n-bytes")) {
    ++		int fd = open(argv[2], O_RDONLY), offset = atoi(argv[3]);
    ++		char buffer[65536];
    ++
    ++		if (fd < 0)
    ++			die_errno("could not open '%s'", argv[2]);
    ++		if (lseek(fd, offset, SEEK_SET) < 0)
    ++			die_errno("could not skip %d bytes", offset);
    ++		for (;;) {
    ++			ssize_t count = read(fd, buffer, sizeof(buffer));
    ++			if (count < 0)
    ++				die_errno("could not read '%s'", argv[2]);
    ++			if (!count)
    ++				break;
    ++			if (write(1, buffer, count) < 0)
    ++				die_errno("could not write to stdout");
    ++		}
    ++		close(fd);
    ++		return 0;
    ++	}
    ++
    + 	fprintf(stderr, "%s: unknown function name: %s\n", argv[0],
    + 		argv[1] ? argv[1] : "(there was none)");
    + 	return 1;
    +
      diff --git a/t/test-lib.sh b/t/test-lib.sh
      --- a/t/test-lib.sh
      +++ b/t/test-lib.sh
    @@ -42,7 +74,8 @@
     -			"$(printf '%s\n' "$@" | sed 1d)")"
     +			"$(if test -n "$GIT_TEST_TEE_OUTPUT_FILE"
     +			   then
    -+				cut -c "$GIT_TEST_TEE_OFFSET-" <"$GIT_TEST_TEE_OUTPUT_FILE"
    ++				test-tool path-utils skip-n-bytes \
    ++					"$GIT_TEST_TEE_OUTPUT_FILE" $GIT_TEST_TEE_OFFSET
     +			   else
     +				printf '%s\n' "$@" | sed 1d
     +			   fi)")"
    @@ -56,17 +89,17 @@
      	fi
      	test_failure=$(($test_failure + 1))
     @@
    - 	write_junit_xml "$(printf '%s\n' \
    - 		"    <testcase $junit_attrs>" "$@" "    </testcase>")"
    - 	junit_have_testcase=t
    -+	if test -n "$GIT_TEST_TEE_OUTPUT_FILE"
    + 	echo >&3 ""
    + 	maybe_teardown_valgrind
    + 	maybe_teardown_verbose
    ++	if test -n "$GIT_TEST_TEE_OFFSET"
     +	then
     +		GIT_TEST_TEE_OFFSET=$(test-tool path-utils file-size \
     +			"$GIT_TEST_TEE_OUTPUT_FILE")
     +	fi
      }
      
    - test_done () {
    + test_skip () {
     @@
      		date +%Y-%m-%dT%H:%M:%S)\""
      	write_junit_xml --truncate "<testsuites>" "  <testsuite $junit_attrs>"
    @@ -74,7 +107,6 @@
     +	if test -n "$GIT_TEST_TEE_OUTPUT_FILE"
     +	then
     +		GIT_TEST_TEE_OFFSET=0
    -+		GIT_TEST_TEE_ERR_OFFSET=0
     +	fi
      fi
      



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux