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

Add Custom PSSA tests for checking Comment Format #232

Open
PlagueHO opened this issue Jun 8, 2018 · 1 comment
Open

Add Custom PSSA tests for checking Comment Format #232

PlagueHO opened this issue Jun 8, 2018 · 1 comment
Labels
enhancement The issue is an enhancement request. help wanted The issue is up for grabs for anyone in the community.

Comments

@PlagueHO
Copy link
Contributor

PlagueHO commented Jun 8, 2018

One of the comment PR corrections I have to make is to correct code comment format. It would be good if we could add PSSA tests for this. There are a few rules I could look at adding:

  1. Check for space after #
  2. Check comment is on it's own line
  3. Check for multi-line comment being in <# #>

Is this something worth implementing? Are there are lot of repos that have violations of this? I might have some violations in the repos I maintain, and this would cause test failures (because I've opted them to fail on style violations), but I'd rather correct them.

@johlju
Copy link
Contributor

johlju commented Jun 9, 2018

I like seeing tests for these. Could be opt-in for custom rules, so would only affect those that opt-in for that, and should more or less be correct already (meaning should be quick to resolve).

Number 3 should also be on separate rows. Could we also test so the text in the comment block is indented?

<#
    Text...
#>

@johlju johlju added enhancement The issue is an enhancement request. help wanted The issue is up for grabs for anyone in the community. labels Jun 9, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement The issue is an enhancement request. help wanted The issue is up for grabs for anyone in the community.
Projects
None yet
Development

No branches or pull requests

2 participants