Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Escape reserved characters teamcity reporter messages #150

Merged
merged 3 commits into from
Sep 17, 2014

Conversation

windelinckx
Copy link
Contributor

Teamcity fails to report tests which contain an unescaped reserved character in the message text.
This means that TeamCity does not report all tests, and can miss failed tests.
Now the TeamCity reporter escapes each of these characters in its messages to TeamCity.

Teamcity fails to report tests which contain an unescaped reserved
character in the message text. Now the teamcity reporter escapes each of
these characters
@@ -55,3 +61,7 @@ TeamcityReporter <- setRefClass("TeamcityReporter", contains = "Reporter",
}
)
)

escapedString <- function(s) {
gsub("(['|]|\\[|\\])", "|\\1", s)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you please name this teamcity_escape?

@windelinckx
Copy link
Contributor Author

function name changed to teamcity_escape as requested

@hadley
Copy link
Member

hadley commented Sep 17, 2014

And can you please add a bullet to NEWS?

@windelinckx
Copy link
Contributor Author

added to NEWS

@hadley hadley merged commit 68d5e2f into r-lib:master Sep 17, 2014
@hadley
Copy link
Member

hadley commented Sep 17, 2014

Thanks - had to merge by hand.

@hadley
Copy link
Member

hadley commented Sep 18, 2014

Since you're familiar with teamcity - is there a standard way to report skipped tests?

@windelinckx
Copy link
Contributor Author

The message

##teamcity[testIgnored name='testName' message='ignore comment']

Will inform teamcity that the test ‘testName’ existed but was ignored.

This replaces the usual test started/ended messages

@hadley
Copy link
Member

hadley commented Sep 18, 2014

Thanks - I just did a fairly major refactoring of the teamcity reporter. Would you mind taking a look? It looks ok to me on casual inspection of the the output.

@windelinckx
Copy link
Contributor Author

Looks good to me

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants