PageRenderTime 154ms CodeModel.GetById 145ms app.highlight 7ms RepoModel.GetById 1ms app.codeStats 0ms

/extra/mason/report/report-tests.factor

http://github.com/abeaumont/factor
Unknown | 30 lines | 23 code | 7 blank | 0 comment | 0 complexity | 948a4cb16b49296b14218de79c8d4b71 MD5 | raw file
 1IN: mason.report.tests
 2USING: io.files io.files.temp io.directories kernel mason.report
 3mason.common mason.config namespaces tools.test xml xml.writer ;
 4
 5{ 0 0 } [ [ ] with-report ] must-infer-as
 6
 7: verify-report ( -- )
 8     [ t ] [ "report" exists? ] unit-test
 9     [ ] [ "report" file>xml drop ] unit-test
10     [ ] [ "report" delete-file ] unit-test ;
11
12"builds" temp-file builds-dir [
13    "resource:extra/mason/report/fake-data/" [
14         [ ] [
15              timings-table pprint-xml
16         ] unit-test
17    
18         [ ] [ successful-report ] unit-test
19         verify-report
20    
21         [ status-error ] [ 1234 compile-failed ] unit-test
22         verify-report
23    
24         [ status-error ] [ 1235 boot-failed ] unit-test
25         verify-report
26    
27         [ status-error ] [ 1236 test-failed ] unit-test
28         verify-report
29    ] with-directory
30] with-variable