Skip to content

Conversation

@michael-o
Copy link
Member

I don't know whether this should be included, but it is trivial to provide. I will let the community decide. If accepted someone should write an IT for that.

@rfscholte
Copy link
Contributor

Writing a unittest is much easier in this case and sufficient enough.

Copy link
Contributor

@eolivelli eolivelli left a comment

Choose a reason for hiding this comment

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

LGTM

I agree that a unit test is enough here

@michael-o
Copy link
Member Author

Just scratching my head how the full boostrap with a unit test would work here since I'd need to analyze stdout/err.

@rfscholte
Copy link
Contributor

IIRC @mthmulders had a similar usecase recently

@mthmulders
Copy link
Contributor

IIRC @mthmulders had a similar usecase recently

Not sure if I understand correctly what you refer to. I recently had a contribution to Plexus Archiver where I wrote a CapturingLog. But given that this is SLF4J, it might be easier to go with something like SLF4J Test.

@michael-o
Copy link
Member Author

The SFL4J test looks promising, but wouldn't it be easier to do just an IT instead of going through a new component?

@rfscholte
Copy link
Contributor

Another option is to increase the visibility of logBuildResumeHint( String resumeBuildHint ) a bit, in the unittest making a new MavenCli with an override of this method. To me an IT is overkill for this check, as it is simple input/output validation, only the difficulty here is that it is writing directly the the logging framework. Better adjust the class to make it testable

@michael-o
Copy link
Member Author

Another option is to have no test at all since this change is straight forward. Pipe input to output unmodified as you can see.

@rfscholte
Copy link
Contributor

I'm fine with no test in this case.

@michael-o
Copy link
Member Author

The issue has been closed as wontfix. So closing this, but leaving the branch for a while.

@jira-importer
Copy link

Resolve #7601

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.

5 participants