aboutsummaryrefslogtreecommitdiff
path: root/src/hooks.py
diff options
context:
space:
mode:
authorCharles Cabergs <me@cacharle.xyz>2020-10-08 17:44:00 +0200
committerCharles Cabergs <me@cacharle.xyz>2020-10-08 17:44:00 +0200
commit72954f36bfcad29cbb4bb324763d4c03b9fa4601 (patch)
tree4647b3916e7285cc39898ce508eddf6b15cea399 /src/hooks.py
parent93ead396473526e5f4849ad2f4194b8cc6c9ce45 (diff)
downloadminishell_test-72954f36bfcad29cbb4bb324763d4c03b9fa4601.tar.gz
minishell_test-72954f36bfcad29cbb4bb324763d4c03b9fa4601.tar.bz2
minishell_test-72954f36bfcad29cbb4bb324763d4c03b9fa4601.zip
Deleted duplicated tests, Added error_eof_to_expected_token hook
Diffstat (limited to 'src/hooks.py')
-rw-r--r--src/hooks.py9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/hooks.py b/src/hooks.py
index 5ec2dde..58cc7a0 100644
--- a/src/hooks.py
+++ b/src/hooks.py
@@ -6,7 +6,7 @@
# By: charles <me@cacharle.xyz> +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ #
# Created: 2020/09/11 16:10:20 by charles #+# #+# #
-# Updated: 2020/10/08 11:43:54 by cacharle ### ########.fr #
+# Updated: 2020/10/08 17:32:12 by cacharle ### ########.fr #
# #
# ############################################################################ #
@@ -99,3 +99,10 @@ def delete_escape(output):
return output.replace("\\", "")
else:
return output
+
+
+def error_eof_to_expected_token(output):
+ return output.replace(
+ "-c: line 1: syntax error: unexpected end of file",
+ "syntax error expected token"
+ )