Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mechanism for catching errors for tests #126

Open
davidzchen opened this issue Mar 10, 2016 · 3 comments
Open

Mechanism for catching errors for tests #126

davidzchen opened this issue Mar 10, 2016 · 3 comments

Comments

@davidzchen
Copy link
Contributor

From our discussion on Tuesday: in general, we should not add a catch mechanism to the language, but having a specific mechanism such as assertThrows or assertError would be useful for testing.

@copumpkin
Copy link

This would be great. There's a parallel discussion going on in Nix right now about whether their equivalent to this (called tryEval) should return details about the error. The argument against providing details is that they can reveal evaluation order, which is pretty icky in a pure language like this.

@copumpkin
Copy link

See NixOS/nix#1000 (comment).

@fkz
Copy link

fkz commented Aug 9, 2016

I also need something like this for NixOS/nixos-homepage#78 where I need to be able to catch all errors so that evaluation of one package can't break evaluation of an other one. (see here: fkz/nix@61dc5a7)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants