非常教程

Erlang 20参考手册

eunit

eunit

模块

eUnit

模块摘要

这个模块是主要的eUnit用户界面。

描述

这个模块是主要的eUnit用户界面。

出口

start() -> term()

启动eUnit服务器。通常,您不需要调用这个函数;它是自动启动的。

stop() -> term()

停止eUnit服务器。通常,您不需要调用这个函数。

test(Tests) -> term()

相当于test(Tests, [])...

test(Tests::term(), Options::[term()]) -> ok | {error, term()}

运行一组测试。格式Tests将在本节中描述。EUnit test representation概述。

例子:

eunit:test(fred)

运行模块中的所有测试。fred以及模块中的任何测试fred_tests,如果存在该模块。

备选方案:

verbose

显示有关正在运行的测试的详细信息。

环境变量eUnit中的选项也包含在选项列表的最后,即优先级低于Options...

Erlang 20

Erlang 是一种通用的面向并发的编程语言,可应付大规模开发活动的程序设计语言和运行环境。

主页 https://www.erlang.org/
源码 https://github.com/erlang/otp
版本 20
发布版本 20.1