Syntax Testing is a type of black box testing technique which is used to examine the format and the grammar of the data inputs used in the software application, either external or input, which may be formally described in technical or established & specified notations such as BNF and could be used to design input validation tests.
Syntax testing is performed to verify and validate the both internal and external data input to the system, against the specified format, file format, database schema, protocol and other similar things. Generally, syntax tests are automated, as they involve the production of large number of tests.
The methodology of syntax testing can be perceived and understood through following steps in the sequential order:
Note*: Garbage condition is the method of testing the system's tolerance against the bad or dirty data. The condition is executed by providing dirty data (invalid data) to the system, which is being not supported by the specified format and grammar of the syntax.
The preferred test strategy which may be followed up to perform syntax testing is to create one error in the input string, one at time while keeping all other components of the string unchanged and correct. Thereafter, the said process needs to repeat until the complete set of test for the single errors get defined. Similarly, the complete set of test for the double error, triple error and so on may be defined and designed. During the whole process, the focus should be at one level, along with the correctness both at its upper and lower level.