MCPcopy Create free account
hub / github.com/boostorg/beast / testMethod

Method testMethod

test/beast/http/message.cpp:343–366  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

341 }
342
343 void
344 testMethod()
345 {
346 header<true> h;
347 auto const vcheck =
348 [&](verb v)
349 {
350 h.method(v);
351 BEAST_EXPECT(h.method() == v);
352 BEAST_EXPECT(h.method_string() == to_string(v));
353 };
354 auto const scheck =
355 [&](string_view s)
356 {
357 h.method_string(s);
358 BEAST_EXPECT(h.method() == string_to_verb(s));
359 BEAST_EXPECT(h.method_string() == s);
360 };
361 vcheck(verb::get);
362 vcheck(verb::head);
363 scheck("GET");
364 scheck("HEAD");
365 scheck("XYZ");
366 }
367
368 void
369 testStatus()

Callers

nothing calls this directly

Calls 1

methodMethod · 0.80

Tested by

no test coverage detected