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

Optionaly output PHPCS standard that caused the problem in UI #177

Merged
merged 1 commit into from
Feb 1, 2022

Conversation

kabalin
Copy link
Member

@kabalin kabalin commented Jan 24, 2022

This is tiny UI improvement to optionally (not checked by default) show the coding standard cause the issue (which will be appended to the message):

image

@stronk7
Copy link
Member

stronk7 commented Jan 24, 2022

98% sold, nice addition!

Only 2 points to comment:

  1. Side comment: I've just seen that he custom CLI runner that we have (run.php) does not support neither the "include warnings" (always enabled) or the "show source" (always disabled). Surely at some point we should try to achieve feature-parity with the UI (although I'm not sure if anybody out there is using it, I'm not).
  2. I'd suggest to add a new scenario (or maybe an example to existing ones) to the behat tests so the new feature (enabled) is tested. As far as this is an UI change, I think it deserves it.

Ciao :-)

@stronk7
Copy link
Member

stronk7 commented Jan 31, 2022

Any chance about point 2 above? Surely we can ignore 1.

@kabalin kabalin force-pushed the ui-output-standard branch from 932a2b9 to bda1929 Compare January 31, 2022 11:52
@kabalin
Copy link
Member Author

kabalin commented Jan 31, 2022

Any chance about point 2 above? Surely we can ignore 1.

Point 2 has been addressed, thanks for review!

Thought for a moment may be standard should always be appended in output (with no checkbox, etc.)

@stronk7
Copy link
Member

stronk7 commented Jan 31, 2022

Hi @kabalin ,

I'm sorry for being picky... but using ´admin/index.php` as laboratory for the test doesn't sound like the better idea (they can be fixed... whatever).

Would you mind using any of the files under <codechecker>/moodle/tests/fixtures instead? I imagine they are way more stable than any file in core.

I'd point you to local/codechecker/moodle/tests/fixtures/files/moodleinternal/problem.php, for example, that is modern and I don't think we'll change it ever. Note that it will work for behat runs (not for normal use, because fixtures are excluded normally). If you want to see the problems in that file normally, you always can hack index.php and add define('BEHAT_SITE_RUNNING', 1); to see exactly what behat will see.

Sorry!

@kabalin
Copy link
Member Author

kabalin commented Feb 1, 2022

You are right @stronk7, I was following a quck way ))

@kabalin kabalin force-pushed the ui-output-standard branch from bda1929 to e8441ce Compare February 1, 2022 14:31
@kabalin
Copy link
Member Author

kabalin commented Feb 1, 2022

Should be ready for another review @stronk7 , sorry.

Copy link
Member

@stronk7 stronk7 left a comment

Choose a reason for hiding this comment

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

Looks perfect, thanks, @kabalin !

@stronk7 stronk7 merged commit 36c025d into moodlehq:master Feb 1, 2022
@kabalin kabalin deleted the ui-output-standard branch February 1, 2022 20:06
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