Export YAML only exports a subset of data

johnny_reilly's Avatar

johnny_reilly

08 Jan, 2015 02:32 PM

Hi,

It looks like the "Export YAML" option doesn't push out everything you'd expect. I was trying it out on https://ci.appveyor.com/project/JohnReilly/proverb-gulp and when I did the export I got this:

version: 1.0.{build}
os: Visual Studio 2015 Preview
before_build:
- ps: >-
    # Pick up nuget packages

    nuget restore Proverb.sln

build:
  project: Proverb.sln
  verbosity: minimal

I was expecting the before_test section to be included like this:

version: 1.0.{build}
os: Visual Studio 2015 Preview
before_build:
- ps: >-
    # Pick up nuget packages

    nuget restore Proverb.sln

build:
  project: Proverb.sln
  verbosity: minimal

before_test:
- ps: >-
    # Locate Chutzpah
    $ChutzpahDir = get-childitem chutzpah.console.exe -recurse | select-object -first 1 | select -expand Directory
    
    # Run tests using Chutzpah and export results as JUnit format to chutzpah-results.xml
    $ChutzpahCmd = "$($ChutzpahDir)\chutzpah.console.exe $($env:APPVEYOR_BUILD_FOLDER)\Proverb.Web.Tests.JavaScript /junit .\chutzpah-results.xml"
    Write-Host $ChutzpahCmd
    Invoke-Expression $ChutzpahCmd
    
    # Print results to host
    #Write-Host "Chutzpah results:"
    #Get-Content .\chutzpah-results.xml
    
    # upload results to AppVeyor as batch
    #$wc = New-Object 'System.Net.WebClient'
    #$wc.UploadFile("https://ci.appveyor.com/api/testresults/junit/$($env:APPVEYOR_JOB_ID)", (Resolve-Path .\chutzpah-results.xml))
    
    # Upload results to AppVeyor one by one
    
    $testsuites = [xml](get-content .\chutzpah-results.xml)
    
    $anyFailures = $FALSE
    foreach ($testsuite in $testsuites.testsuites.testsuite) {
        write-host " $($testsuite.name)"
        foreach ($testcase in $testsuite.testcase){
            $failed = $testcase.failure
            $time = $testsuite.time
            if ($testcase.time) { $time = $testcase.time }
            if ($failed) {
                write-host "Failed   $($testcase.name) $($testcase.failure.message)"
                Add-AppveyorTest $testcase.name -Outcome Failed -FileName $testsuite.name -ErrorMessage $testcase.failure.message -Duration $time
            }
            else {
                write-host "Passed   $($testcase.name)"
                Add-AppveyorTest $testcase.name -Outcome Passed -FileName $testsuite.name -Duration $time
            }
        }
    }

if ($anyFailures -eq $TRUE){
    write-host "Failing build as there are broken tests"
    $host.SetShouldExit(1)
}

Is this a bug?

  1. Support Staff 1 Posted by Feodor Fitsner on 08 Jan, 2015 03:54 PM

    Feodor Fitsner's Avatar

    How does UI look like - could you paste a screenshot?

    -Feodor

  2. 2 Posted by johnny_reilly on 09 Jan, 2015 10:14 AM

    johnny_reilly's Avatar

    This is the tests tab Feodor

  3. 3 Posted by johnny_reilly on 09 Jan, 2015 10:14 AM

    johnny_reilly's Avatar

    This is the YAML tab

  4. 4 Posted by johnny_reilly on 29 Jan, 2015 09:26 AM

    johnny_reilly's Avatar

    Hi Feodor,

    Was there any news on this issue? It's not impacting me now that I have a nice boilerplate appveyor.yml to work with but I'm guessing it may be an issue for others...

  5. Support Staff 5 Posted by Feodor Fitsner on 29 Jan, 2015 02:42 PM

    Feodor Fitsner's Avatar

    Oh, it was fixed!

    -Feodor

  6. 6 Posted by johnny_reilly on 30 Jan, 2015 04:34 PM

    johnny_reilly's Avatar

    Smashing!

  7. Ilya Finkelshteyn closed this discussion on 25 Aug, 2018 01:53 AM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac

Recent Discussions

21 Aug, 2019 11:06 PM
21 Aug, 2019 02:08 PM
21 Aug, 2019 01:37 PM
21 Aug, 2019 10:21 AM
21 Aug, 2019 09:10 AM

 

21 Aug, 2019 05:56 AM
21 Aug, 2019 03:08 AM
20 Aug, 2019 11:33 PM
20 Aug, 2019 08:07 PM
20 Aug, 2019 05:50 PM
20 Aug, 2019 12:35 PM