improve regex test
Project: http://git-wip-us.apache.org/repos/asf/couchdb-mango/repo Commit: http://git-wip-us.apache.org/repos/asf/couchdb-mango/commit/b2f62f1d Tree: http://git-wip-us.apache.org/repos/asf/couchdb-mango/tree/b2f62f1d Diff: http://git-wip-us.apache.org/repos/asf/couchdb-mango/diff/b2f62f1d Branch: refs/heads/2787-merge-repos Commit: b2f62f1d0f6872be960246461e82845c6fa09e9a Parents: 97162fd Author: Tony Sun <tony....@cloudant.com> Authored: Wed Aug 26 01:53:49 2015 -0700 Committer: Tony Sun <tony....@cloudant.com> Committed: Wed Aug 26 01:53:49 2015 -0700 ---------------------------------------------------------------------- src/mango_util.erl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/couchdb-mango/blob/b2f62f1d/src/mango_util.erl ---------------------------------------------------------------------- diff --git a/src/mango_util.erl b/src/mango_util.erl index 2d25bdc..6b150e7 100644 --- a/src/mango_util.erl +++ b/src/mango_util.erl @@ -417,6 +417,6 @@ is_number_string_test() -> ?assert(is_number_string("-1.0")), ?assertNot(is_number_string("hello")), ?assertNot(is_number_string("")), - ?assertMatch({re_pattern, _, _, _, _}, mochiglobal:get(mango_numstring_re)). + ?assertMatch({match, _}, re:run("1.0", mochiglobal:get(mango_numstring_re))). -endif.