| 155 | } |
| 156 | |
| 157 | int test_container_no_vhost() { |
| 158 | // explicitly setting an empty virtual-host will cause the Open |
| 159 | // performative to be sent without a hostname field present. |
| 160 | // Sadly whether or not a 'hostname' field was received cannot be |
| 161 | // determined from here, so just exercise the code |
| 162 | proton::connection_options opts; |
| 163 | opts.virtual_host(""); |
| 164 | test_handler th("127.0.0.1", opts); |
| 165 | proton::container(th).run(); |
| 166 | ASSERT_EQUAL(th.peer_vhost, ""); |
| 167 | return 0; |
| 168 | } |
| 169 | |
| 170 | std::vector<proton::symbol> make_caps(const std::string& s) { |
| 171 | std::vector<proton::symbol> caps; |
no test coverage detected