Skip to content

Commit a11e84d

Browse files
authored
fix(specs): fix missing params and types (#772)
1 parent 1a760ad commit a11e84d

File tree

17 files changed

+981
-161
lines changed

17 files changed

+981
-161
lines changed

.github/.cache_version

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
0.0.9
1+
0.0.10

config/generation.config.js

+5-8
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,10 @@ module.exports = {
2828

2929
// PHP
3030
'!clients/algoliasearch-client-php/*',
31-
'!clients/algoliasearch-client-php/lib/*',
32-
'!clients/algoliasearch-client-php/lib/Cache/**',
33-
'!clients/algoliasearch-client-php/lib/Exceptions/**',
34-
'!clients/algoliasearch-client-php/lib/Http/**',
35-
'!clients/algoliasearch-client-php/lib/Log/**',
36-
'!clients/algoliasearch-client-php/lib/RequestOptions/**',
37-
'!clients/algoliasearch-client-php/lib/RetryStrategy/**',
38-
'!clients/algoliasearch-client-php/lib/Support/**',
31+
'clients/algoliasearch-client-php/lib/Api/*',
32+
'clients/algoliasearch-client-php/lib/Model/**',
33+
'clients/algoliasearch-client-php/lib/Configuration/*',
34+
'clients/algoliasearch-client-php/lib/ApiException.php',
35+
'clients/algoliasearch-client-php/lib/ObjectSerializer.php',
3936
],
4037
};

generators/src/main/java/com/algolia/codegen/cts/manager/JavaCTSManager.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ public JavaCTSManager(String client) {
1515

1616
@Override
1717
public void addSupportingFiles(List<SupportingFile> supportingFiles) {
18-
supportingFiles.add(new SupportingFile("build.mustache", ".", "build.gradle"));
18+
supportingFiles.add(new SupportingFile("build.mustache", "", "build.gradle"));
1919
}
2020

2121
@Override

generators/src/main/java/com/algolia/codegen/cts/tests/ParametersWithDataType.java

+7-1
Original file line numberDiff line numberDiff line change
@@ -305,7 +305,13 @@ private void handleModel(
305305
}
306306
if (varSpec == null) {
307307
throw new CTSException(
308-
"Parameter " + entry.getKey() + " not found in " + paramName + ". You might have a type conflict in the spec for " + baseType
308+
"Parameter '" +
309+
entry.getKey() +
310+
"' not found in '" +
311+
paramName +
312+
"'. You might have a type conflict in the spec for '" +
313+
baseType +
314+
"'"
309315
);
310316
}
311317

scripts/ci/githubActions/createMatrix.ts

+1-6
Original file line numberDiff line numberDiff line change
@@ -128,12 +128,7 @@ async function getSpecMatrix(): Promise<void> {
128128
};
129129

130130
for (const client of CLIENTS) {
131-
// `algoliasearch` is an aggregation of client
132-
if (client === 'algoliasearch') {
133-
continue;
134-
}
135-
136-
// The `lite` spec is created by the `search` spec
131+
// The `algoliasearch` spec is created by the `search` spec, for the `lite` JavaScript client.
137132
const bundledSpecName = client === 'algoliasearch' ? 'search' : client;
138133

139134
matrix.toRun.push(client);

scripts/ci/husky/__tests__/pre-commit.test.js

-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ describe('micromatch', () => {
2424

2525
'clients/algoliasearch-client-php/.gitignore',
2626
'clients/algoliasearch-client-php/lib/Api/SearchClient.php',
27-
'clients/algoliasearch-client-php/lib/Cache/FileCacheDriver.php',
2827

2928
'tests/output/java/build.gradle',
3029
'tests/output/java/settings.gradle',

specs/abtesting/common/parameters.yml

+5-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,11 @@ endAt:
2222

2323
createdAt:
2424
type: string
25-
description: End date for the A/B test expressed as YYYY-MM-DDThh:mm:ssZ.
25+
description: Creation date for the A/B test expressed as YYYY-MM-DDThh:mm:ssZ.
26+
27+
updatedAt:
28+
type: string
29+
description: Update date for the A/B test expressed as YYYY-MM-DDThh:mm:ssZ.
2630

2731
name:
2832
type: string

specs/abtesting/common/schemas/ABTest.yml

+3
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@ ABTest:
2020
description: A/B test significance based on conversion data. Should be > 0.95 to be considered significant (no matter which variant is winning).
2121
endAt:
2222
$ref: '../parameters.yml#/endAt'
23+
updatedAt:
24+
$ref: '../parameters.yml#/updatedAt'
2325
createdAt:
2426
$ref: '../parameters.yml#/createdAt'
2527
name:
@@ -34,6 +36,7 @@ ABTest:
3436
- name
3537
- createdAt
3638
- endAt
39+
- updatedAt
3740
- conversionSignificance
3841
- clickSignificance
3942
- abTestID

0 commit comments

Comments
 (0)