From c96df58a88b60c7501b3c8a758c0277c17088371 Mon Sep 17 00:00:00 2001 From: Corentin Le Gall Date: Thu, 19 Jul 2018 15:57:30 +0200 Subject: Changed doc to GitBook format + added doc -Changed README.md to a complet GitBook doc. -Added explanations about EvtGrpReceived functions. -Corrected mistakes + reduced lines length. Change-Id: I1a077ddf6acb520a9158de658d3c09b12a2029d4 Signed-off-by: Corentin Le Gall --- .../LuaUnitAssertionFunctions/5_TypeAssertions.md | 38 ++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 docs/WriteYourTests/Reference/LuaUnitAssertionFunctions/5_TypeAssertions.md (limited to 'docs/WriteYourTests/Reference/LuaUnitAssertionFunctions/5_TypeAssertions.md') diff --git a/docs/WriteYourTests/Reference/LuaUnitAssertionFunctions/5_TypeAssertions.md b/docs/WriteYourTests/Reference/LuaUnitAssertionFunctions/5_TypeAssertions.md new file mode 100644 index 0000000..843f651 --- /dev/null +++ b/docs/WriteYourTests/Reference/LuaUnitAssertionFunctions/5_TypeAssertions.md @@ -0,0 +1,38 @@ +# Type assertions + +The following functions all perform type checking on their argument. If the +received value is not of the right type, the failure message will contain the +expected type, the received type and the received value to help you identify +better the problem. + +* **_AFT.assertIsNumber(value)** + + Assert that the argument is a number (integer or float) + +* **_AFT.assertIsString(value)** + + Assert that the argument is a string. + +* **_AFT.assertIsTable(value)** + + Assert that the argument is a table. + +* **_AFT.assertIsBoolean(value)** + + Assert that the argument is a boolean. + +* **_AFT.assertIsFunction(value)** + + Assert that the argument is a function. + +* **_AFT.assertIsUserdata(value)** + + Assert that the argument is a userdata. + +* **_AFT.assertIsThread(value)** + + Assert that the argument is a coroutine (an object with type thread ). + +* **_AFT.assertNotIsThread(value)** + + Assert that the argument is a not coroutine (an object with type thread ). \ No newline at end of file -- cgit 1.2.3-korg