Jul 14 in Python
Q: What are Usage of OK_ and EQ_ in NOSE Python?

1 Answer

Jul 14 also contain methods ok_ and eq_, which function similar to assert and assert_equals respectively.

You can optionally pass an error message that can be displayed when a test fails.

Usage of ok_ and eq_ is shown in below example by defining two functions in

from import ok_, eq_

def test_using_ok():


def test_using_eq():

    eq_(2+3, 5)
Click here to read more about Python
Click here to read more about Insurance

Related questions

Jul 14 in Python
Jul 16 in Python
Jul 2 in Python