85 Commits

Author SHA1 Message Date
William Cheng
b768e42704
Update junit to newer version (4.13.1) (#7690)
* update junit to newer version

* update junit to newer version
2020-10-14 10:10:32 +08:00
William Cheng
2fd23f505e
Prepare 5.0.0-SNAPSHOT (#7347)
* Revert "Prepare 5.0.0-beta2 release (#7345)"

This reverts commit 212b4f784742744b7b238607dcefb23ec9db64d7.

* update readme
2020-09-04 15:31:54 +08:00
William Cheng
212b4f7847
Prepare 5.0.0-beta2 release (#7345)
* update version

* update doc

* update samples
2020-09-04 13:03:45 +08:00
ParakhMittal
7bb8a8d9ff
Update apiInvoker.mustache and sample file for akka-scala client for issue #7258 fix (#7259)
* Update apiInvoker.mustache

In scala-akka-client code that is getting generated, addAuthentication method is called after setting headers using header parameter in the below mentioned line
addAuthentication(request.credentials)(
      httpRequest.withHeaders(headers(request.headerParams))
    )

However, in addAuthentication method, we are using withHeaders method that overwrites the headers set using header parameters. So, I am proposing to
change the addAuthentication method be replacing withHeaders() method to addHeader() to add authentication header to the list of already existing headers.

* Update ApiInvoker.scala

Added changes to sample for the client generator code change
2020-08-23 21:42:16 +08:00
William Cheng
dd6e8ccc3d
replace ~ with $user.home (#6985) 2020-07-18 17:07:03 +08:00
William Cheng
0707b4bb20
[Scala] setup Ivy cache directory (#6978)
* use ivy2 cache

* use ~/.ivy2 cache dir

* add pom.xml to openapi-generator-ignore

* update scala-akka sample

* use ~ for home directory
2020-07-18 15:48:47 +08:00
William Cheng
8689625af3
Fix default response (#6625)
* fix isDefault in response

* fix response

* update samples

* fix scala akka template

* fix elm template

* remove commented code

* remove eof

* update elm samples
2020-06-12 15:49:26 +08:00
William Cheng
6abc4fdab2
Migrate all scala generators to use OAS3 (#6407)
* migrate all scala generators to use oas3

* add back pom.xml for scala-sttp

* skip form model in scalaz

* fix scala lagom tests

* add new files

* skip form models in scala finch petstore

* update samples
2020-05-25 23:09:34 +08:00
Jim Schubert
70ca93570e
[core][general] Add metadata file tracking to aid in "Golden Tests" regeneration (#6325) 2020-05-22 16:48:32 -04:00
William Cheng
1d606499ee Merge remote-tracking branch 'origin/5.0.x' 2020-05-06 22:51:05 +08:00
William Cheng
6484c03518
Test scala akka petstore client in CI (#6118)
* test scala akka in ci

* fix compilation error

* fix scala akka test

* add tests
2020-05-01 16:47:38 +08:00
Aleksandr Nekrasov
8e4452e383
[scala-akka-http] fixed getOffsetDateTimeHeader and removed broken test due invalid v2 spec (#6109) 2020-04-30 10:53:14 +08:00
William Cheng
5a9b0fcf9e update samples 2020-04-21 02:22:55 +08:00
Aleksandr Nekrasov
ea2fd0f1b6
fix scala-akka java8 serializers (#5742)
* fix scala-akka java8 serializers

* regenerate samples for akka-http
2020-04-02 12:18:21 +08:00
William Cheng
a0ca253218
update samples (#5722) 2020-03-27 13:55:55 +08:00
Jim Schubert
accacfe39a
[scala] Regenerate akka sample (#5622) 2020-03-17 21:34:44 -04:00
Aleksandr Nekrasov
5beccd12b6
[scala][templates] java 8 dates support (#5291)
* [scala][akka-http-client] java8 dates support

* scala-akka readme doc updated

* DateSerializers renamed

* rename serializers

* move date-library option to abstractScala

* generators docs updated

* enum defined for date libraries

* Backport to scala-http-client

* fix scala-akka-client date serializers

* fix typo in docs

* switch scala templates to java8 (jsr-310) date library by default

* update scala samples with java8 date library

* update scala generators docs with java8 default date library

* fix scala-play-server generator cli options as only java8 dateLibrary supported

* fix scalaz DateTimeCodecs template to support java8

* scalaz ci test againt java7 removed as it generate scala 2.11.8 client which is java8 based
2020-03-17 15:54:24 +08:00
Marcin Kubala
0cf5d356cc
Scala-Akka: Add missing body to PATCH requests (#5605) 2020-03-17 01:02:06 -04:00
Aleksandr Nekrasov
84250973be
[scala] strip model class name for all scala generators (#5439)
* stripped parameter enabled for all scala based generators

* scala samples updated

* docs generators updated

* fix scalatra. regenerated by openapi3 script.
manually removed enum default value from scalatra example due bug in schema extraction
2020-02-28 20:44:02 +08:00
Aleksandr Nekrasov
1bba3a563e
[scala] fix akka-scala-client template compilation warnings (#5106)
* fix akka-scala-client template compilation warnings

add COOKIE location authorization key
regenerate template

* fix scala akka-http client model imports

* fix #4004 custom package name in reference.conf

* fix scaka-akka codegen test
2020-02-06 22:15:43 +08:00
William Cheng
04af5e0445 Merge remote-tracking branch 'origin/master' into 4.3.x 2020-01-20 15:04:34 +08:00
Jim Schubert
25036e48d5
[scala] Support for Set when array has uniqueItems=true (#4926)
* [scala] Set support for unique arrays

This includes and builds upon community contribution for better Set support in Scala.
It makes property + model work as expected with Set and default values
across all Scala generators. Included tests to account for new changes.

This also reverts the community contribution to remove ListBuffer
imports and change the default for array to ListBuffer. Users should use
the instantiation types map to modify the desired array instantiation
type. Any new default should target a new minor release after community
discussion, as it affects all existing SDKs generated with
openapi-generator.

* [scala] Improve default handling of monadic collection type

* [scala] Regenerate samples

* Update ScalaPlayFrameworkServerCodegen.java

Scala Play defaulted to List and should continue to do so.

Co-authored-by: František Kocun <frantisek.kocun@gmail.com>
2020-01-05 09:20:56 -05:00
sullis
178a3e24bd upgrade to JUnit 4.13 (#4899) 2020-01-02 13:20:29 +08:00
Pelle Stenild Coltau
f6dbd48b9c [Swift4] Expanding CodableHelper with added date and JSON customisations (#3365)
* Expanding CodableHelper with a more customisable dateFormatter and JSON en-/decoder.

* Ran ./bin/swift4-petstore.sh

* Ran ./bin/swift4-petstore-all.sh again after merge from master.

* Ran ./bin/swift4-petstore-all.sh again after building.

* Ran ./bin/swift4-petstore-all.sh again after rebase latest from upstream master.

* sync master, update samples

* Built and ran ./bin/swift4-petstore-all.sh

* Re-adding code which disappeared in rebase from master.

* Fixed test

* [swift] remove old classes
2019-12-16 17:40:53 +08:00
Sergey Terentyev
e901132ea9 #3957 - Removed hardcoded baseUrl (#3964) 2019-09-28 17:41:16 +08:00
Joël Vimenet
d518407471 Add scala-akka tests (#2650) 2019-04-17 15:18:03 +08:00
William Cheng
d4244be654
fix scala akka return type (#2510) 2019-03-26 18:54:09 +08:00
William Cheng
3e065db2c6
better operation id handling in scala generators (#2490) 2019-03-25 13:13:09 +08:00
Joël Vimenet
5074f4d9c5 Update akka scala generator (#2472)
* Update akka scala generator

* Upgrade scala version to 2.12.8
* Upgrade Akka version
* Migrate from spray to Akka HTTP

* Update client sample

* Fix pom.xml generation to be equivalent to build.sbt
2019-03-25 13:12:56 +08:00
William Cheng
111a3626b2
update scala akka dependencies (#1294) 2018-10-23 16:34:27 +08:00
William Cheng
22049db8c1
fix enum value, update dart petstore samples (#1193) 2018-10-09 07:08:04 +08:00
Antonio Bellezza
8b47984e3c [Scala-Akka] Generate default values for optional model fields (#1119)
* Generate default values for optional model fields in scala-akka

Fix #1118

* Updated akka-client petstore with defaults for optional model fields

* update petstore sample with scalafmt
2018-09-29 21:21:06 +08:00
William Cheng
fc35bb17d0
Add option to enable scalafmt for code formatting (#1032)
* add option to enable scalafmt for code formatting

* fix typo
2018-09-14 16:58:27 +08:00
William Cheng
748d1d70cb
update groupId in pom (#779) 2018-08-10 15:48:19 +08:00
Akihito Nakano
e23b2f6fcc [Scala][client] Rename script, sample folder, template dir (#334)
* Rename scripts akka-scala-petstore.sh -> scala-akka-petstore.sh

* Rename sample folder: akka-scala -> scala-akka

* Rename templateDir: akka-scala -> scala-akka-client

* Rename scripts: scala-petstore.sh -> scala-httpclient-petstore.sh

* Rename sample folder: scala -> scala-httpclient

* Rename templateDir: scala -> scala-httpclient

* update circle pom.xml for new scala path

* remove duplicated scala test
2018-06-21 17:28:58 +08:00