minitest-ok:'ok {1 + 1} == 2',而不是'assert_equal 2,1 + 1'

时间:2024-06-16 11:10:20
【文件属性】:

文件名称:minitest-ok:'ok {1 + 1} == 2',而不是'assert_equal 2,1 + 1'

文件大小:14KB

文件格式:ZIP

更新时间:2024-06-16 11:10:20

Ruby

最小测试::好 Minitest :: Ok是Minitest的一个很好的帮助程序库。 例如: ok { 1 + 1 } == 2 # same as assert_equal 2, 1+1 ok { 1 + 1 } > 1 # same as assert_operator 1+1, :>, 1 ok { '123' } =~ / \d +/ # same as assert_match /\d+/, '123' ok { [ ] } . kind_of? ( Array ) # same as assert_kind_of Array, [] ok { 1 .. 9 } . include? ( 1 ) # same as assert_includes 1, 1..9 ok { 1 }


【文件预览】:
minitest-ok-dev
----bin()
--------console(336B)
--------setup(115B)
----Rakefile(1KB)
----test()
--------test_helper.rb(269B)
--------minitest()
----.gitignore(87B)
----lib()
--------minitest()
----minitest-ok.gemspec(989B)
----README.md(6KB)
----MIT-LICENSE(1KB)

网友评论