File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
.learn/exercises/03.3-your-first-route Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -34,15 +34,15 @@ def test_declare_variable2():
3434 path = 'src/app.py'
3535 with open (path , 'r' ) as content_file :
3636 content = content_file .read ()
37- regex = re .compile (r"@app\.route(\s*)\((\s*)'\ /[a-zA-Z0-9]+' (\s*),(\s*)methods=(\s*)\[(\s*)' GET' (\s*)\](\s*)\)" )
37+ regex = re .compile (r"@app\.route(\s*)\((\s*)[\'\"]\ /[a-zA-Z0-9]+[\'\"] (\s*),(\s*)methods=(\s*)\[(\s*)[\'\"] GET[\'\"] (\s*)\](\s*)\)" )
3838 assert bool (regex .search (content )) == True
3939
4040@pytest .mark .it ("Make sure '/todos' is the route you specified inside the @app.route decorator" )
4141def test_declare_variable3 ():
4242 path = 'src/app.py'
4343 with open (path , 'r' ) as content_file :
4444 content = content_file .read ()
45- regex = re .compile (r"'\ /todos' " )
45+ regex = re .compile (r"[\'\"]\ /todos[\'\"] " )
4646 assert bool (regex .search (content )) == True
4747
4848@pytest .mark .it ("Endpoint for path '/todos' must exist" )
You can’t perform that action at this time.
0 commit comments