Skip to content

Commit 4880c33

Browse files
committed
update hello checks
1 parent 02dc1f7 commit 4880c33

File tree

4 files changed

+32
-3
lines changed

4 files changed

+32
-3
lines changed
File renamed without changes.

hello/__init__.py renamed to me/__init__.py

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,11 @@ def emma():
1717
check50.run("./hello").stdin("Emma").stdout("Emma").exit()
1818

1919
@check50.check(compiles)
20-
def rodrigo():
21-
"""responds to name Rodrigo"""
22-
check50.run("./hello").stdin("Rodrigo").stdout("Rodrigo").exit()
20+
def inno():
21+
"""responds to name Inno"""
22+
check50.run("./hello").stdin("Inno").stdout("Inno").exit()
23+
24+
@check50.check(compiles)
25+
def kamryn():
26+
"""responds to name Kamryn"""
27+
check50.run("./hello").stdin("Kamryn").stdout("Kamryn").exit()

world/.cs50.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
check50:
2+
files: &check50_files
3+
- !exclude "*"
4+
- !require hello.c
5+
6+
submit50:
7+
files: *check50_files

world/__init__.py

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
import check50
2+
import check50.c
3+
4+
@check50.check()
5+
def exists():
6+
"""hello.c exists"""
7+
check50.exists("hello.c")
8+
9+
@check50.check(exists)
10+
def compiles():
11+
"""hello.c compiles"""
12+
check50.c.compile("hello.c", lcs50=True)
13+
14+
@check50.check(compiles)
15+
def world():
16+
"""hello.c prints \"hello, world\""""
17+
check50.run("./hello").stdout("hello, world").exit()

0 commit comments

Comments
 (0)