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

ToString Tests #731

Closed
wants to merge 11 commits into from
Closed

ToString Tests #731

wants to merge 11 commits into from

Conversation

aferr
Copy link
Collaborator

@aferr aferr commented Sep 22, 2022

This adds tests to ast_string.h which we apparently already had and already used for other tests in the repository. However, this code didn't have any tests itself. So rather than have two ways of making a string from the AST, I updated ast_string.h so that it is good enough for the uses of the ToString methods in the AST and added some tests for ast_string.h. In a follow-up PR, I will deprecate the ToString methods in the AST class and use just ast_string.h for the remaining tests thereby satisfying #720.

@aferr aferr marked this pull request as ready for review September 22, 2022 16:56
@aferr aferr requested a review from bgogul September 22, 2022 16:56
@aferr
Copy link
Collaborator Author

aferr commented Sep 22, 2022

I am not deprecating the ToString methods of ast.h in this PR and will only do that as a separate PR in interest of keeping the PRs simpler.

Copy link
Collaborator

@bgogul bgogul left a comment

Choose a reason for hiding this comment

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

I have some questions before I do a deeper review. Can you take a look, please?

src/ir/auth_logic/ast_construction_says_assertion_test.cc Outdated Show resolved Hide resolved
src/ir/auth_logic/ast_string.h Outdated Show resolved Hide resolved
@aferr aferr requested a review from bgogul September 27, 2022 11:24
@aferr
Copy link
Collaborator Author

aferr commented Sep 28, 2022

@bgogul ready for re-review

Copy link
Collaborator

@bgogul bgogul left a comment

Choose a reason for hiding this comment

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

Thank you, Andrew. I have some clean up suggestions. Looks good otherwise.

src/ir/auth_logic/ast_string_test.cc Outdated Show resolved Hide resolved
src/ir/auth_logic/ast_string_test.cc Outdated Show resolved Hide resolved
src/ir/auth_logic/ast_string.h Outdated Show resolved Hide resolved
src/ir/auth_logic/ast_string.h Outdated Show resolved Hide resolved
src/ir/auth_logic/ast_string.h Outdated Show resolved Hide resolved
src/ir/auth_logic/ast_string.h Outdated Show resolved Hide resolved
src/ir/auth_logic/ast_string.h Outdated Show resolved Hide resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants