SpdPnd98 / pe

0 stars 0 forks source link

Inconsistent chaining command behaviour #3

Open SpdPnd98 opened 2 years ago

SpdPnd98 commented 2 years ago

If I did find test &&, the application is able to detect that no commands are chained

Screenshot from 2021-11-12 16-44-12.png Screenshot from 2021-11-12 16-43-58.png

But if I have multiple chaining commands find test && && && && &&, it doesn't exhibit the same behaviour.

Screenshot from 2021-11-12 16-43-46.png

nus-pe-bot commented 2 years ago

Team's Response

In case 1 && is taken as chaining find test and ` which result infind testbeing evaluated and there are no ambiguities. Case 2 the chain command will chainfind testand&& && && &&` the latter being an unknown command format hence error message is raised.

Items for the Tester to Verify

:question: Issue response

Team chose [response.Rejected]

Reason for disagreement: I expect both the commands above to consistently exhibit either one of these behaviours:

  1. && && && && should not be an unknown format, but viewed as multiple chain commands. What I expect is && && && && to be chained with (spaces) as well. So it should be

    1. find test chain (space)
    2. ` (space) chain `(space)
    3. ` (space) chain `(space)
    4. ` (space) chain `(space)
    5. ` (space) chain `(space)
  2. find 3 && should show unknown format, as not having left command should be invalid. This is also stated in your UG, where there has to be two commands (both left and right!)

Screenshot from 2021-11-17 02-14-37.png

Since both is shown, this hints to me that there is a problem with the parser format and/or potential incorrect use of .trim().