This concept is used to create an atomic assertion to test something.
An assert concept always return with something that will be a result
of a test. Better is you use an assert to return a test method like
this example:
: test_any [
...
...
return .assert(...)] typeof String
You can use the following assertions:
- for testing one logical condition, returns true if condition is true
.assertTrue( logicalCondition )
.assertTrue( message, logicalCondition )
for testing an equality between two concepts
.assertEquals( one_concept, other_concept)
.assertEquals( message, one_concept, other_concept)
for testing if something is equal nil
.assertNil( concept )
.assertNil( message, concept )
for testing if something is not equal nil
.assertNotNil( concept )
.assertNotNil( message, concept )
to direct throw failed assertion
.fail()
.fail( message )
.failNotEquals( message, one_concept, other_concept )
Methods inherited from: Concept
| cloneConcept, extendsConcept, fromXML, getAllInheritedConcepts, getConceptAttribute, getConceptAttributeField, getConceptAttributeFields, getConceptAttributes, getConceptConstructors, getConceptElement, getConceptElementField, getConceptElementFields, getConceptElements, getConceptLabel, getConceptMethod, getConceptMethods, getConceptOperators, getConceptType, getErrorHandler, getInheritedConcepts, getResourceURI, hasConceptAttribute, hasConceptElement, hasConceptMethod, hasPath, isHidden, loadContent, setConceptLabel, setErrorHandler, setHidden, setShowEmpty, showEmpty, toTXT, toXML, setResourceURI |
|
| Parameters: |
| $e : | a concept |
| $a : | other concept |
|
this method tests if a two concept is equals
| Parameters: |
| $msg : | test method message |
| $e : | a concept |
| $a : | other concept |
|
this method tests if two concept is equals and can specify a message
tests if concept is nil
| Parameters: |
| $msg : | message from test method |
| $c : | concept for testing |
|
tests if concept is nil with message
tests if concept is not nil
| Parameters: |
| $msg : | message from test method |
| $c : | concept for testing |
|
tests if concept is not nil with message
| Parameters: |
| $msg : | message from test method |
| $cond : | logical condition to test |
|
tests if the logical condition is true with message
| Parameters: |
| $cond : | logical condition to test |
|
tests if the logical condition is true
| Parameters: |
| $msg : | fail massage from test method |
|
throws directly a failed assert with message
throws directly a failed assert
| Parameters: |
| $msg : | fail massage from test method |
| $e : | one concept |
| $a : | other concept |
|
throws directly a failed assert to message the concepts in parameters is not equals