The testing of DTWFileIO module will be partly incorporated in the system
testing because this module depends on the org.dtrend.DTWData
module
very heavily. Tests M-FIO04 and M-FIO06 test the functionality G-05
marked essential in the Software Requirements Specification .
In each case where a fake or misformatted file name is mentioned,
the file name contains characters which are not allowed in the underlying
filesystem, ie. c:\??????.???
or c:\..?..?.???
. The term
misformatted data stands for data which does not correspond to the
formatting specified in the Software Requirements Specification .
M-FIO01: method org.dtrend.DTWFileIO.openDataSet()
java.lang.String
object containing:
DTWFileIOException
thrown to the caller
M-FIO02: method org.dtrend.DTWFileIO.loadRecord()
int
value representing the wanted record index
float[]
containing the values at the specified index
org.dtrend.DTWFileIOException
thrown to the caller
M-FIO03: method org.dtrend.DTWFileIO.closeDataSet()
org.dtrend.DTWFileIOException
thrown to the caller
M-FIO04: method org.dtrend.DTWFileIO.loadTemplates()
org.dtrend.DTWData
object.
java.lang.String
object Filename
,
org.dtrend.DTWData
object DataObject
Filename
contains a real file name and DataObject
is functional
Filename
contains a fake file name and DataObject
is functional
Filename
contains misformatted data
DataObject
has the new templates in its data structures
org.dtrend.DTWFileIOException
is thrown to the caller
org.dtrend.DTWFileIOException
is thrown to the caller, DataObject
has the templates that were placed in the loaded file before the misformatted row.
M-FIO05: method org.dtrend.DTWFileIO.saveTemplates()
org.dtrend.DTWData
object and write them into the opened file.
java.lang.String
object Filename
,
org.dtrend.DTWData
object DataObject
Filename
contains a real file name and DataObject
is functional
Filename
contains a fake file name and DataObject
is functional
Filename
is created and it contains the templates that were stored in the DataObject
at the time of the method call
org.dtrend.DTWFileIOException
is thrown to the caller
M-FIO06: method org.dtrend.DTWFileIO.loadObservation()
org.dtrend.DTWData
object.
java.lang.String
object Filename
,
org.dtrend.DTWData
object DataObject
Filename
contains a real file name and DataObject
is functional
Filename
contains a fake file name and DataObject
is functional
Filename
contains misformatted data
DataObject
has the new observation in its data structures
org.dtrend.DTWFileIOException
is thrown to the caller
org.dtrend.DTWFileIOException
is thrown to the caller
M-FIO07: method org.dtrend.DTWFileIO.saveObservation()
org.dtrend.DTWData
object and save it into the opened file.
java.lang.String
object Filename
,
org.dtrend.DTWData
object DataObject
Filename
contains a real file name and DataObject
is functional
Filename
contains a fake file name and DataObject
is functional
Filename
is created and it
contains the observation stored in the DataObject
at the time of
the method call
org.dtrend.DTWFileIOException
is thrown to the caller
M-FIO08: method org.dtrend.DTWFileIO.saveLog()
org.dtrend.DTWData
object and write them into the opened
file.
java.lang.String
object Filename
,
org.dtrend.DTWData
object DataObject
Filename
contains a real file name and DataObject
is functional
Filename
contains a fake file name and DataObject
is functional
Filename
is created and it
contains the logged information of the last algorithm execution.
org.dtrend.DTWFileIOException
is thrown to the caller