All Downloads are FREE. Search and download functionalities are using the official Maven repository.

mustache.typescript-fetch.api_test.mustache Maven / Gradle / Ivy

There is a newer version: 1.0.48
Show newest version
{{>licenseInfo}}

import * as api from "./api"
import { Configuration } from "./configuration"

const config: Configuration = {}

{{#apiInfo}}
{{#apis}}
{{#operations}}
describe("{{classname}}", () => {
  let instance: api.{{classname}}
  beforeEach(function() {
    instance = new api.{{classname}}(config)
  });

{{#operation}}
  test("{{operationId}}", () => {
    {{#allParams}}
    const {{{paramName}}}: {{^isPrimitiveType}}api.{{/isPrimitiveType}}{{{dataType}}} = {{>api_test_default_value}}
    {{/allParams}}
    return expect(instance.{{operationId}}({{#allParams}}{{{paramName}}}, {{/allParams}}{})).resolves.toBe(null)
  })
{{/operation}}
})

{{/operations}}
{{/apis}}
{{/apiInfo}}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy