()
| 566 | |
| 567 | #[test] |
| 568 | fn test_parse_query_method() { |
| 569 | let yaml = r#" |
| 570 | openapi: 3.2.0 |
| 571 | info: |
| 572 | title: Test |
| 573 | version: '1.0' |
| 574 | paths: |
| 575 | /test: |
| 576 | query: |
| 577 | summary: Test query |
| 578 | responses: |
| 579 | '200': |
| 580 | description: OK |
| 581 | "#; |
| 582 | |
| 583 | let openapi: OpenAPI = OpenAPI::yaml(yaml).unwrap(); |
| 584 | let test_path = openapi.paths.get("/test").unwrap(); |
| 585 | assert!(test_path.query.is_some()); |
| 586 | assert_eq!( |
| 587 | test_path.query.as_ref().unwrap().summary.as_ref().unwrap(), |
| 588 | "Test query" |
| 589 | ); |
| 590 | } |
| 591 | } |
nothing calls this directly
no outgoing calls
no test coverage detected