Skip to content

Conversation

@auduchinok
Copy link
Member

Simplifies development loop when making changes to the parser and want to see what files parsing is changed compared to the baseline and what has changed.

@auduchinok auduchinok requested a review from a team as a code owner April 14, 2023 12:55
elif not equals then
File.WriteAllText(tmpPath, actual)
else
File.Delete(tmpPath)
Copy link
Member

Choose a reason for hiding this comment

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

Would be good to avoid IO-attempt in the happy path

Copy link
Member Author

Choose a reason for hiding this comment

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

Do you think it is something that would make a measurable difference in these tests?

Copy link
Member

Choose a reason for hiding this comment

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

These things tend to accummulate over time with more tests and more functinalities in the suite.
If it can be easily avoided, we shouldn't be doing unnecessary IO when tests are running.

Copy link
Member Author

Choose a reason for hiding this comment

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

It looks like these tests access IO enough already for it not to matter much here. It simplifies the work with the parser, as it's easy to see what got changed without requiring to clean this files manually later.

Copy link
Member Author

Choose a reason for hiding this comment

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

Or I could, for example, check some environment variable indicating a CI run if you share a pointer

Copy link
Member

Choose a reason for hiding this comment

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

@auduchinok auduchinok force-pushed the syntaxTree-test-tmp branch from 36e1d8a to 40579fa Compare April 17, 2023 14:38
@vzarytovskii vzarytovskii enabled auto-merge (squash) April 18, 2023 11:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

4 participants