File Coverage

xsi/Error.xsi
Criterion Covered Total %
statement 29 29 100.0
branch 56 112 50.0
condition n/a
subroutine n/a
pod n/a
total 85 141 60.2


line stmt bran cond sub pod time code
1             MODULE = Protocol::WebSocket::Fast PACKAGE = Protocol::WebSocket::Fast
2             PROTOTYPES: DISABLE
3            
4             BOOT {
5 36 50         Stash s(__PACKAGE__);
6            
7 36 50         Stash ecstash("Protocol::WebSocket::Fast::Error", GV_ADD);
8 864 50         xs::exp::create_constants(ecstash, {
    50          
    50          
    50          
    50          
    50          
    50          
    50          
    50          
    50          
    50          
    50          
    50          
    50          
    50          
    50          
    50          
    50          
    50          
    50          
    50          
    50          
    50          
    50          
    100          
    0          
9 36 50         {"garbage_after_connect", xs::out(make_error_code(errc::garbage_after_connect))},
10 36 50         {"unsupported_version", xs::out(make_error_code(errc::unsupported_version))},
11 36 50         {"response_code_101", xs::out(make_error_code(errc::response_code_101))},
12 36 50         {"connection_mustbe_upgrade", xs::out(make_error_code(errc::connection_mustbe_upgrade))},
13 36 50         {"upgrade_mustbe_websocket", xs::out(make_error_code(errc::upgrade_mustbe_websocket))},
14 36 50         {"sec_accept_missing", xs::out(make_error_code(errc::sec_accept_missing))},
15 36 50         {"method_mustbe_get", xs::out(make_error_code(errc::method_mustbe_get))},
16 36 50         {"http_1_1_required", xs::out(make_error_code(errc::http_1_1_required))},
17 36 50         {"body_prohibited", xs::out(make_error_code(errc::body_prohibited))},
18 36 50         {"invalid_opcode", xs::out(make_error_code(errc::invalid_opcode))},
19 36 50         {"control_fragmented", xs::out(make_error_code(errc::control_fragmented))},
20 36 50         {"control_payload_too_big", xs::out(make_error_code(errc::control_payload_too_big))},
21 36 50         {"not_masked", xs::out(make_error_code(errc::not_masked))},
22 36 50         {"max_frame_size", xs::out(make_error_code(errc::max_frame_size))},
23 36 50         {"close_frame_invalid_data", xs::out(make_error_code(errc::close_frame_invalid_data))},
24 36 50         {"initial_continue", xs::out(make_error_code(errc::initial_continue))},
25 36 50         {"fragment_no_continue", xs::out(make_error_code(errc::fragment_no_continue))},
26 36 50         {"max_message_size", xs::out(make_error_code(errc::max_message_size))},
27 36 50         {"deflate_negotiation_failed", xs::out(make_error_code(errc::deflate_negotiation_failed))},
28 36 50         {"control_frame_compression", xs::out(make_error_code(errc::control_frame_compression))},
29 36 50         {"inflate_error", xs::out(make_error_code(errc::inflate_error))},
30 36 50         {"unexpected_rsv", xs::out(make_error_code(errc::unexpected_rsv))},
31 36 50         {"invalid_utf8", xs::out(make_error_code(errc::invalid_utf8))},
32 432 50         });
33 18 50         xs::exp::autoexport(ecstash);
    50          
34            
35 18 50         s.add_const_sub("error_category", xs::out(&error_category));
    50          
36             }