[BUG] The generated Ruby client's code violates its own Rubocop rule.
Created by: autopp
Bug Report Checklist
-
Have you provided a full/minimal spec to reproduce the issue? -
Have you validated the input using an OpenAPI validator (example)? -
What's the version of OpenAPI Generator used? -
Have you search for related issues/PRs? -
What's the actual output vs expected output? -
[Optional] Bounty to sponsor the fix (example)
Description
The generated Ruby client's code violates its own Rubocop rule.
openapi-generator version
$ java -jar modules/openapi-generator-cli/target/openapi-generator-cli.jar version
4.0.0-SNAPSHOT
$ git log --oneline -n 1
0b10092262 (HEAD -> master, origin/master, origin/HEAD, autopp/master) [python-flask] [python-aiohttp] [bug] Fixed handling of dotted module names (#2041)
OpenAPI declaration file content or url
swagger: "2.0"
info:
title: "Example API"
version: "1.0.0"
host: "example.com"
paths:
/foo:
get:
responses:
200:
description: ''
Command line used for generation
$ java -jar modules/openapi-generator-cli/target/openapi-generator-cli.jar generate --skip-validate-spec -g ruby -o /tmp/gem -i 'https://gist.githubusercontent.com/autopp/86b54a836b45332da307b2a998d9cd1f/raw/2d4d7ce07450a5a99d9dc32bc12449a9eac5afce/example.yml'
Steps to reproduce
- Run the above command to generate client code for Ruby.
- Go to
/tmp/gem
and runrubocop
to check style of the generated model code. - Get warning in
lib/openapi_client/api/default_api.rb
:$ (cd /tmp/gem; rubocop) Inspecting 13 files ........C.... Offenses: lib/openapi_client/api/default_api.rb:61:1: C: Layout/EmptyLinesAroundClassBody: Extra empty line detected at class body end. 13 files inspected, 1 offense detected
Related issues/PRs
N/A