Skip to content
This repository has been archived by the owner on Mar 25, 2021. It is now read-only.

Support multiple files in checkstyle formatter #1811

Merged
merged 2 commits into from
Dec 1, 2016

Conversation

fsahmad
Copy link
Contributor

@fsahmad fsahmad commented Dec 1, 2016

PR checklist

  • Addresses an existing issue: #0000
  • New feature, bugfix, or enhancement
    • Includes tests
  • Documentation update

What changes did you make?

Found an issue when integrating tslint with jenkins (using checkstyle formatter), the formatter did not generate separate file nodes in the outputted XML, instead simply reporting all errors under the first file.

To fix this I:

  • Modified checkstyleFormatter.ts to sort failures by filename, and generate file nodes for each unique filename
  • Modified test case to test failures in multiple files

Is there anything you'd like reviewers to focus on?

The checkstyleFormatter test was reusing another formatter's test input file, I've followed this pattern to add a second file in the test. It might be better to create two test input files specifically for the checkstyleFormatter...

- Modified checkstyleFormatter.ts to sort failures by filename, and generate file nodes for each unique filename
- Modified test case to test failures in multiple files
@palantirtech
Copy link
Member

Thanks for your interest in palantir/tslint, @fsahmad! Before we can accept your pull request, you need to sign our contributor license agreement - just visit https://cla.palantir.com/ and follow the instructions. Once you sign, I'll automatically update this pull request.

@nchen63 nchen63 merged commit a8d3a43 into palantir:master Dec 1, 2016
@nchen63
Copy link
Contributor

nchen63 commented Dec 1, 2016

@fsahmad thanks!

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

Successfully merging this pull request may close these issues.

3 participants