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

Add tests #42

Merged
merged 1 commit into from
Jan 19, 2022
Merged

Add tests #42

merged 1 commit into from
Jan 19, 2022

Conversation

Smit-create
Copy link
Collaborator

No description provided.

@namannimmo10
Copy link
Collaborator

Thanks! Just curious: once #41 is merged, do we really need lpython_tests.py?
We could add tests as separate units in different files and run the whole test suite with ctest.

@Thirumalai-Shaktivel
Copy link
Collaborator

do we really need lpython_tests.py?

Nope, as you said we can add separate tests (in separate files) for each implementation.
Then, we execute
./run_tests.py to check whether all the test passes.
./run_tests.py -u to update the tests.

@Smit-create
Copy link
Collaborator Author

Okay, then let's wait for #41 to merge.

@certik
Copy link
Contributor

certik commented Jan 18, 2022

From now on, let's simply add new files into tests/ and add them into tests/tests.toml.

lpython_tests.py Outdated Show resolved Hide resolved
lpython_tests.py Outdated Show resolved Hide resolved
lpython_tests.py Outdated Show resolved Hide resolved
lpython_tests.py Outdated Show resolved Hide resolved
lpython_tests.py Outdated Show resolved Hide resolved
lpython_tests.py Outdated Show resolved Hide resolved
lpython_tests.py Outdated Show resolved Hide resolved
lpython_tests.py Outdated Show resolved Hide resolved
lpython_tests.py Outdated Show resolved Hide resolved
lpython_tests.py Outdated Show resolved Hide resolved
lpython_tests.py Outdated Show resolved Hide resolved
lpython_tests.py Outdated Show resolved Hide resolved
lpython_tests.py Outdated Show resolved Hide resolved
@certik
Copy link
Contributor

certik commented Jan 18, 2022

@Smit-create, I added hints which files you can put those tests in. Then register them in tests/tests.toml and then do ./run_tests.py -u, which will generate the reference results in tests/reference/*, simply add them to git and create a PR.

lpython_tests.py Outdated Show resolved Hide resolved
lpython_tests.py Outdated Show resolved Hide resolved
Copy link
Contributor

@certik certik left a comment

Choose a reason for hiding this comment

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

This looks good to me. +1 to merge if tests pass.

@certik certik merged commit 0f3c870 into lcompilers:main Jan 19, 2022
@Smit-create Smit-create deleted the test_1 branch January 19, 2022 04:48
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.

None yet

4 participants