Test Script
for PA1
Sample Dialog from a
Test Program (Name
is replaced by test case)
ÏϧÏ
ÏϧÏWelcome to the Student Grade Program
ÏϧÏ
¼¼§ÏEnter the path for the input file to use: x
ÏϧÏSorry that file doesn't exist.
Try again.
ÏϧÏ
¼¼§ÏEnter the path for the input file to use: abc
ÏϧÏSorry that file doesn't exist.
Try again.
ÏϧÏ
¼¼§ÏEnter the path for the input file to use: test.csv
ÏϧÏ
¼¼§ÏEnter the path and name for the output file to use: a:/out.txt
ÏϧÏSorry that file doesn't exist.
Try again.
ÏϧÏ
¼¼§ÏEnter the path and name for the output file to use: out.txt
ÏϧÏEchoing data from test.csv
ÏϧÏ_Should be A,111,93,93,93,93,93
ÏϧÏ_Should be A-,222,92,92,92,92,92
ÏϧÏ_Should be B+,333,89.98,89.98,89,89,89
ÏϧÏ_Should be B ,444,85,85,85,85,85
ÏϧÏ_Should be B-,555,79.99,79.99,80,80,80
ÏϧÏ_Should be C+,666,79,79,79,79,79
ÏϧÏ_Should be C,777,75,75,75,75,75
ÏϧÏ_Should be C-,888,70,70,70,70,70
ÏϧÏ_Should be D+,999,69,69,69,69,69
ÏϧÏ_Should be D ,1111,65,65,65,65,65
ÏϧÏ_Should be F,2222,59,59,59,59,59
ÏϧÏ_Bad id,abc,75,75,75,75,75
ÏϧÏ__Bad id: abc 0 used
ÏϧÏ_Bad Lab,4444,NG,75,75,75,75
ÏϧÏ__Bad Lab Grade: NG 0 used
ÏϧÏ_Bad PA,5555,75,NG,75,75,75
ÏϧÏ__Bad Program Grade: NG 0 used
ÏϧÏ_Bad Ex1,6666,75,75,x,75,75
ÏϧÏ__Bad Exam 1 Grade: x 0 used
ÏϧÏ_Bad Ex2,7777,75,75,75,z,75
ÏϧÏ__Bad Exam 2 Grade: z 0 used
ÏϧÏ_Bad Final,8888,75,75,75,75,NG
ÏϧÏ__Bad Final Exam Grade: NG -1 used
ÏϧÏ_Bad Final 2,9999,90,90,90,90,xx
ÏϧÏ__Bad Final Exam Grade: xx -1 used
ÏϧÏ_Bad all ,axxxxx,a;ldfj,;alkgjdf,;alkjdf,;aldjf,a;slg
ÏϧÏ__Bad id: axxxxx 0 used
ÏϧÏ__Bad Lab Grade: a;ldfj 0 used
ÏϧÏ__Bad Program Grade: ;alkgjdf 0 used
ÏϧÏ__Bad Exam 1 Grade: ;alkjdf 0 used
ÏϧÏ__Bad Exam 2 Grade: ;aldjf 0 used
ÏϧÏ__Bad Final Exam Grade: a;slg -1 used
ÏϧÏ_Records read and processed: 19
ÏϧÏFinished reading records from test.csv
ÏϧÏYou will find output data in out.txt
ÏϧÏBye y'all
Ï
ÏContents
of output file
ÏϧÏname#id#programs#labs#exam1#exam2#final#average#letter
ÏϧÏShould be A#111#93.0#93.0#93#93#93#93.0#A
ÏϧÏShould be A-#222#92.0#92.0#92#92#92#92.0#A-
ÏϧÏShould be B+#333#89.98#89.98#89#89#89#89.29400000000001#B+
ÏϧÏShould be B #444#85.0#85.0#85#85#85#85.0#B
ÏϧÏShould be B-#555#79.99#79.99#80#80#80#79.997#B-
ÏϧÏShould be C+#666#79.0#79.0#79#79#79#79.0#C+
ÏϧÏShould be C#777#75.0#75.0#75#75#75#75.0#C
ÏϧÏShould be C-#888#70.0#70.0#70#70#70#70.0#C-
ÏϧÏShould be D+#999#69.0#69.0#69#69#69#69.0#D+
ÏϧÏShould be D #1111#65.0#65.0#65#65#65#65.0#D
ÏϧÏShould be F#2222#59.0#59.0#59#59#59#59.0#F
ÏϧÏBad id#0#75.0#75.0#75#75#75#75.0#C
ÏϧÏBad Lab#4444#0.0#75.0#75#75#75#67.5#D+
ÏϧÏBad PA#5555#75.0#0.0#75#75#75#60.0#D
ÏϧÏBad Ex1#6666#75.0#75.0#0#75#75#60.0#D
ÏϧÏBad Ex2#7777#75.0#75.0#75#0#75#60.0#D
ÏϧÏBad Final#8888#75.0#75.0#75#75#-1#52.2#F
ÏϧÏBad Final 2#9999#90.0#90.0#90#90#-1#62.7#F
ÏϧÏBad all #0#0.0#0.0#0#0#-1#-0.3#F
ÏϧÏ
ÏÏ©