This repository was archived by the owner on Jun 6, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 6 files changed +11
-44
lines changed
example/src/main/java/example
service/src/test/java/com/theokanning/openai/service Expand file tree Collapse file tree 6 files changed +11
-44
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -12,25 +12,19 @@ jobs:
1212 steps :
1313 - uses : actions/checkout@v3
1414
15- - name : Set up JDK 17
15+ - name : Set up JDK 1.8
1616 uses : actions/setup-java@v3
1717 with :
1818 distribution : temurin
19- java-version : 17
19+ java-version : 8
2020
2121 - name : Test
2222 run : ./gradlew test
2323 env :
2424 OPENAI_TOKEN : ${{ secrets.OPENAI_TOKEN }}
2525
26- - name : Set up JDK 1.8
27- uses : actions/setup-java@v3
28- with :
29- distribution : temurin
30- java-version : 8
31-
3226 - name : Publish
33- run : ./gradlew build -x :example:build publish --no-parallel
27+ run : ./gradlew build publish --no-parallel
3428 env :
3529 ORG_GRADLE_PROJECT_mavenCentralUsername : ${{ secrets.SONATYPE_NEXUS_USERNAME }}
3630 ORG_GRADLE_PROJECT_mavenCentralPassword : ${{ secrets.SONATYPE_NEXUS_PASSWORD }}
Original file line number Diff line number Diff line change 1717 distribution : temurin
1818 java-version : 8
1919
20- - name : Compile Artifacts
21- run : ./gradlew api:compileJava client:compileJava service:compileJava
22-
23- - name : Set up JDK 17
24- uses : actions/setup-java@v3
25- with :
26- distribution : temurin
27- java-version : 17
28-
29- - name : Compile Tests
30- run : ./gradlew compileTestJava
20+ - name : Compile
21+ run : ./gradlew compileJava compileTestJava
Original file line number Diff line number Diff line change @@ -11,11 +11,11 @@ jobs:
1111 steps :
1212 - uses : actions/checkout@v3
1313
14- - name : Set up JDK 17
14+ - name : Set up JDK 1.8
1515 uses : actions/setup-java@v3
1616 with :
1717 distribution : temurin
18- java-version : 17
18+ java-version : 8
1919
2020 - name : Test
2121 run : ./gradlew test --stacktrace
Original file line number Diff line number Diff line change @@ -36,7 +36,7 @@ public static void main(String... args) {
3636 .name ("unit" )
3737 .type ("string" )
3838 .description ("The temperature unit, can be 'celsius' or 'fahrenheit'" )
39- .enumValues (Set . of ("celsius" , "fahrenheit" ))
39+ .enumValues (new HashSet <>( Arrays . asList ("celsius" , "fahrenheit" ) ))
4040 .required (true )
4141 .build ())
4242 .build ();
Original file line number Diff line number Diff line change 77import com .theokanning .openai .completion .chat .*;
88import org .junit .jupiter .api .Test ;
99
10- import java .util .ArrayList ;
11- import java .util .HashMap ;
12- import java .util .List ;
13- import java .util .Set ;
14- import java .util .Collections ;
10+ import java .util .*;
1511
1612import static org .junit .jupiter .api .Assertions .*;
1713
@@ -164,7 +160,7 @@ void createChatCompletionWithDynamicFunctions() {
164160 .name ("unit" )
165161 .type ("string" )
166162 .description ("The temperature unit, can be 'celsius' or 'fahrenheit'" )
167- .enumValues (Set . of ("celsius" , "fahrenheit" ))
163+ .enumValues (new HashSet <>( Arrays . asList ("celsius" , "fahrenheit" ) ))
168164 .required (true )
169165 .build ())
170166 .build ();
@@ -273,7 +269,7 @@ void streamChatCompletionWithDynamicFunctions() {
273269 .name ("unit" )
274270 .type ("string" )
275271 .description ("The temperature unit, can be 'celsius' or 'fahrenheit'" )
276- .enumValues (Set . of ("celsius" , "fahrenheit" ))
272+ .enumValues (new HashSet <>( Arrays . asList ("celsius" , "fahrenheit" ) ))
277273 .required (true )
278274 .build ())
279275 .build ();
You can’t perform that action at this time.
0 commit comments