Created
March 24, 2021 20:46
-
-
Save jxxcarlson/4504497ba8f4aac098b9b4b3d7bbdbe7 to your computer and use it in GitHub Desktop.
Testing elm-embed
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
➜ tests git:(master) ✗ python3 characterization-test.py | |
Could not find the elm-embed binary in PATH. | |
Specify the location of elm-embed like this: | |
characterization-test.py /path/to/elm-embed | |
Traceback (most recent call last): | |
File "/Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-test.py", line 125, in <module> | |
main() | |
File "/Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-test.py", line 51, in main | |
m.test(elmEmbedPath, outputDir) | |
File "/Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-tests/elm-embed.py", line 7, in test | |
subprocess.call([elmEmbedPath], stdout=out, stderr=err) | |
File "/opt/homebrew/Cellar/python@3.9/3.9.2_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/subprocess.py", line 349, in call | |
with Popen(*popenargs, **kwargs) as p: | |
File "/opt/homebrew/Cellar/python@3.9/3.9.2_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/subprocess.py", line 951, in __init__ | |
self._execute_child(args, executable, preexec_fn, close_fds, | |
File "/opt/homebrew/Cellar/python@3.9/3.9.2_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/subprocess.py", line 1823, in _execute_child | |
raise child_exception_type(errno_num, err_msg, err_filename) | |
FileNotFoundError: [Errno 2] No such file or directory: 'elm-embed' | |
➜ tests git:(master) ✗ python3 characterization-test.py elm-embed-0.1.0-mac-x64 | |
elm-embed: 0.1.0 (compatible with Elm 0.19.1) | |
ERR! elm-embed | |
The output and snapshot doesn't match. | |
Keys: | |
- = file/dir pressent in snapshot but not in output | |
+ = file/dir pressent in output but not in snapshot | |
m = file content missmatch | |
Diff: | |
m STDERR | |
Output dir: /var/folders/ml/vl09g4313rb1jd6y9zvcd6200000gn/T/tmppwa01j93-elm-embed | |
Snapshot dir: /Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-tests/elm-embed | |
To make current output be the snapshot, run: | |
rm -r /Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-tests/elm-embed && mv /var/folders/ml/vl09g4313rb1jd6y9zvcd6200000gn/T/tmppwa01j93-elm-embed /Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-tests/elm-embed | |
OK elm-embed--version | |
ERR! elm-embed--help | |
The output and snapshot doesn't match. | |
Keys: | |
- = file/dir pressent in snapshot but not in output | |
+ = file/dir pressent in output but not in snapshot | |
m = file content missmatch | |
Diff: | |
m STDERR | |
Output dir: /var/folders/ml/vl09g4313rb1jd6y9zvcd6200000gn/T/tmpyih0k_0l-elm-embed--help | |
Snapshot dir: /Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-tests/elm-embed--help | |
To make current output be the snapshot, run: | |
rm -r /Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-tests/elm-embed--help && mv /var/folders/ml/vl09g4313rb1jd6y9zvcd6200000gn/T/tmpyih0k_0l-elm-embed--help /Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-tests/elm-embed--help | |
Traceback (most recent call last): | |
File "/Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-test.py", line 125, in <module> | |
main() | |
File "/Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-test.py", line 55, in main | |
diffs = gatherDiffs(diff) | |
File "/Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-test.py", line 102, in gatherDiffs | |
diffs += [ [ "removed", i ] for i in diff.left_only ] | |
File "/opt/homebrew/Cellar/python@3.9/3.9.2_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/filecmp.py", line 248, in __getattr__ | |
self.methodmap[attr](self) | |
File "/opt/homebrew/Cellar/python@3.9/3.9.2_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/filecmp.py", line 142, in phase1 | |
a = dict(zip(map(os.path.normcase, self.left_list), self.left_list)) | |
File "/opt/homebrew/Cellar/python@3.9/3.9.2_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/filecmp.py", line 248, in __getattr__ | |
self.methodmap[attr](self) | |
File "/opt/homebrew/Cellar/python@3.9/3.9.2_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/filecmp.py", line 134, in phase0 | |
self.left_list = _filter(os.listdir(self.left), | |
PermissionError: [Errno 13] Permission denied: 'characterization-tests/elm-embed-init--help' | |
➜ tests git:(master) ✗ python3 characterization-test.py elm-embed-0.1.0-mac-x64 | |
elm-embed: 0.1.0 (compatible with Elm 0.19.1) | |
ERR! elm-embed | |
The output and snapshot doesn't match. | |
Keys: | |
- = file/dir pressent in snapshot but not in output | |
+ = file/dir pressent in output but not in snapshot | |
m = file content missmatch | |
Diff: | |
m STDERR | |
Output dir: /var/folders/ml/vl09g4313rb1jd6y9zvcd6200000gn/T/tmpuod7wtwu-elm-embed | |
Snapshot dir: /Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-tests/elm-embed | |
To make current output be the snapshot, run: | |
rm -r /Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-tests/elm-embed && mv /var/folders/ml/vl09g4313rb1jd6y9zvcd6200000gn/T/tmpuod7wtwu-elm-embed /Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-tests/elm-embed | |
OK elm-embed--version | |
ERR! elm-embed--help | |
The output and snapshot doesn't match. | |
Keys: | |
- = file/dir pressent in snapshot but not in output | |
+ = file/dir pressent in output but not in snapshot | |
m = file content missmatch | |
Diff: | |
m STDERR | |
Output dir: /var/folders/ml/vl09g4313rb1jd6y9zvcd6200000gn/T/tmppuwnl550-elm-embed--help | |
Snapshot dir: /Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-tests/elm-embed--help | |
To make current output be the snapshot, run: | |
rm -r /Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-tests/elm-embed--help && mv /var/folders/ml/vl09g4313rb1jd6y9zvcd6200000gn/T/tmppuwnl550-elm-embed--help /Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-tests/elm-embed--help | |
Traceback (most recent call last): | |
File "/Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-test.py", line 125, in <module> | |
main() | |
File "/Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-test.py", line 55, in main | |
diffs = gatherDiffs(diff) | |
File "/Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-test.py", line 102, in gatherDiffs | |
diffs += [ [ "removed", i ] for i in diff.left_only ] | |
File "/opt/homebrew/Cellar/python@3.9/3.9.2_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/filecmp.py", line 248, in __getattr__ | |
self.methodmap[attr](self) | |
File "/opt/homebrew/Cellar/python@3.9/3.9.2_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/filecmp.py", line 142, in phase1 | |
a = dict(zip(map(os.path.normcase, self.left_list), self.left_list)) | |
File "/opt/homebrew/Cellar/python@3.9/3.9.2_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/filecmp.py", line 248, in __getattr__ | |
self.methodmap[attr](self) | |
File "/opt/homebrew/Cellar/python@3.9/3.9.2_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/filecmp.py", line 134, in phase0 | |
self.left_list = _filter(os.listdir(self.left), | |
PermissionError: [Errno 13] Permission denied: 'characterization-tests/elm-embed-init--help' | |
➜ tests git:(master) ✗ sudo rm -r /Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-tests/elm-embed | |
➜ tests git:(master) ✗ sudo mv /var/folders/ml/vl09g4313rb1jd6y9zvcd6200000gn/T/tmpuod7wtwu-elm-embed /Users/carlson/dev/elm/experimental/elm-embed/tests/characterization-tests/elm-embed | |
➜ tests git:(master) ✗ ls |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment