-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #64 from younesaassila/fix/58
Fix #58
- Loading branch information
Showing
3 changed files
with
25 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
pytest | ||
pytest-cov | ||
pytest-timeout | ||
six | ||
pytest-clarity | ||
mypy | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,14 @@ | ||
# ############################################################################ # | ||
# **************************************************************************** # | ||
# # | ||
# ::: :::::::: # | ||
# test_run.py :+: :+: :+: # | ||
# +:+ +:+ +:+ # | ||
# By: charles <[email protected]> +#+ +:+ +#+ # | ||
# By: yaassila <[email protected]> +#+ +:+ +#+ # | ||
# +#+#+#+#+#+ +#+ # | ||
# Created: 2021/02/08 19:56:48 by charles #+# #+# # | ||
# Updated: 2021/02/11 20:27:07 by charles ### ########.fr # | ||
# Updated: 2023/08/31 14:00:00 by yaassila ### ########.fr # | ||
# # | ||
# ############################################################################ # | ||
# **************************************************************************** # | ||
|
||
import pytest | ||
|
||
|
@@ -82,3 +82,21 @@ def test_basic(): | |
} | ||
""" | ||
assert output == run_all(input) | ||
|
||
|
||
@pytest.mark.timeout(15) | ||
def test_function_call_in_comment(): | ||
input = """ | ||
#include "libft.h" | ||
/* | ||
The bzero() function erases the data in the n bytes of the memory starting at the location pointed to by s, by writing zeros (bytes containing '\\0') to that area. | ||
The explicit_bzero() function performs the same task as bzero(). It differs from bzero() in that it guarantees that compiler optimizations will not remove the erase operation if the compiler deduces that the operation is "un-necessary". | ||
*/ | ||
void bzero(void *s, size_t n) | ||
{ | ||
unsigned char *ptr_s; | ||
} | ||
""" | ||
run_all(input) |