Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issues/86 v2 #87

Merged
merged 93 commits into from
Sep 15, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
93 commits
Select commit Hold shift + click to select a range
a13eb6e
No longer need most of the overrides
lf-jason-jia Sep 11, 2023
aa3e02e
Remove more overrides
lf-jason-jia Sep 11, 2023
6fc19d1
Generate clients, lots to fix
lf-jason-jia Sep 11, 2023
af705cd
Prefer list
lf-jason-jia Sep 11, 2023
1368072
Manual fix to generated code due to ComponentModel.Annotations not pa…
lf-jason-jia Sep 11, 2023
765e540
Server session is gone for good
lf-jason-jia Sep 11, 2023
b605f24
Remove unnecessary long names
lf-jason-jia Sep 11, 2023
10d9517
Update attributes APIs
lf-jason-jia Sep 11, 2023
5d2d6ea
Update entries APIs
lf-jason-jia Sep 11, 2023
b57b1e6
Update APIs for field definitions
lf-jason-jia Sep 12, 2023
675c280
Update APIs for link definitions
lf-jason-jia Sep 12, 2023
d3952b9
Update APIs for listing repositories
lf-jason-jia Sep 12, 2023
28ba91a
Update APIs for search
lf-jason-jia Sep 12, 2023
77f3fc7
Update APIs for tag definitions
lf-jason-jia Sep 12, 2023
3503709
WIP: update APIs for template definitions
lf-jason-jia Sep 12, 2023
b0ade44
Finish updating APIs for template definitions
lf-jason-jia Sep 12, 2023
033d5d9
No longer needed
lf-jason-jia Sep 12, 2023
a0d8fbf
No need to use so many fully qualified names
lf-jason-jia Sep 12, 2023
00b7521
Again, no need for fully qualified name
lf-jason-jia Sep 12, 2023
adc81f0
Use shorter names
lf-jason-jia Sep 12, 2023
e45b4fb
Use null propagation
lf-jason-jia Sep 12, 2023
14c66d4
Fix CreateEntry method
lf-jason-jia Sep 12, 2023
99daa99
Add missing API
lf-jason-jia Sep 12, 2023
1b64aa1
Fix test util methods and use simple import for entry creation
lf-jason-jia Sep 12, 2023
6e084ff
Server session is gone
lf-jason-jia Sep 12, 2023
214a54b
Update parameter naming for entries API
lf-jason-jia Sep 12, 2023
50ea7ed
Update tests for attributes APIs
lf-jason-jia Sep 12, 2023
11192d4
Update tests for audit reason APIs
lf-jason-jia Sep 12, 2023
e177ba7
For tests of attribtues APIs, rename test classes names and their tes…
lf-jason-jia Sep 12, 2023
2302dcc
Rename tests for audit reasons since their names have changed
lf-jason-jia Sep 12, 2023
2106cfc
Add standard assertion for collection response
lf-jason-jia Sep 12, 2023
d29e663
Update tests for copy entry API
lf-jason-jia Sep 12, 2023
cb88bc7
Use AssertCollectionResponse
lf-jason-jia Sep 12, 2023
f161200
Update tests for create and copy entry APIs
lf-jason-jia Sep 12, 2023
0e02da4
Update entry deletion related tests
lf-jason-jia Sep 12, 2023
c1682fc
Rename since the API name has changed
lf-jason-jia Sep 12, 2023
8fe580b
Remove the tests since the API is gone
lf-jason-jia Sep 12, 2023
5780107
Update tests related to template definition listing API
lf-jason-jia Sep 12, 2023
a2a8b7e
Delete since the API no longer exists
lf-jason-jia Sep 13, 2023
00440af
Update list fields related tests
lf-jason-jia Sep 13, 2023
fbd0797
Update list link related tests
lf-jason-jia Sep 13, 2023
48a72aa
Update list entries related tests
lf-jason-jia Sep 13, 2023
97f3a76
Update list tag related tests
lf-jason-jia Sep 13, 2023
809ffe1
Update tests for set template API
lf-jason-jia Sep 13, 2023
b7191b3
Update set tags related tests
lf-jason-jia Sep 13, 2023
554417b
Update set links related tests
lf-jason-jia Sep 13, 2023
b690ab1
Update tests related to set fields
lf-jason-jia Sep 13, 2023
56342b9
Update tests related to template removal API
lf-jason-jia Sep 13, 2023
27b9726
Update entry update API tests
lf-jason-jia Sep 13, 2023
b47b24b
Update tests related to import entry
lf-jason-jia Sep 13, 2023
ec05da2
Update get entry related tests
lf-jason-jia Sep 13, 2023
f2783d9
Fix entry update tests
lf-jason-jia Sep 13, 2023
f96568a
Minor naming and syntax fixes
lf-jason-jia Sep 13, 2023
9df6d43
Update tests related to field definitions
lf-jason-jia Sep 13, 2023
4de04bd
Update test names as API names have changed
lf-jason-jia Sep 13, 2023
7c1a46b
Udpate tests related to link definitions
lf-jason-jia Sep 13, 2023
188efc4
Update tests related to listing repositories
lf-jason-jia Sep 13, 2023
c8f7c3f
Tests can run on .NET 6
lf-jason-jia Sep 13, 2023
05104fa
More readable
lf-jason-jia Sep 13, 2023
f76d7d9
Use new assertion
lf-jason-jia Sep 13, 2023
3921c28
Update all search API releated tests
lf-jason-jia Sep 13, 2023
ce01c67
Update tests realted to simple search API
lf-jason-jia Sep 13, 2023
87ab792
Update tag definition API related tests
lf-jason-jia Sep 13, 2023
c7eca09
Update test names since their APIs have changed
lf-jason-jia Sep 13, 2023
de7ccf0
Update tests related to task listing
lf-jason-jia Sep 14, 2023
909fb6f
Update tests related to task cancellation
lf-jason-jia Sep 14, 2023
fb3a628
Update tests related to retriving a single template definition
lf-jason-jia Sep 14, 2023
1374a20
Update tests related to listing of template definitions
lf-jason-jia Sep 14, 2023
27a9778
Update list template fiels by template name tests
lf-jason-jia Sep 14, 2023
426387d
Update tests related to ListTemplateFieldDefinitionsByTemplateId
lf-jason-jia Sep 14, 2023
d3462a0
Pass in scopes
lf-jason-jia Sep 14, 2023
d028012
Test no need to support .net core 3
lf-jason-jia Sep 14, 2023
5debc1e
Simplify test naming
lf-jason-jia Sep 14, 2023
0046fd7
ImportEntryRequest must have its Name field filled
lf-jason-jia Sep 14, 2023
53c7876
Problem details have changed
lf-jason-jia Sep 14, 2023
189b337
FieldToUpdate needs its Name field set
lf-jason-jia Sep 14, 2023
916e331
Fix set link test
lf-jason-jia Sep 14, 2023
097ea84
LFS behavior has changed, use a more robust check
lf-jason-jia Sep 14, 2023
7d1f0f6
Pass in repository ID instead of task ID
lf-jason-jia Sep 14, 2023
3a19927
Non-null check is consistent with the JS client
lf-jason-jia Sep 14, 2023
7292eb0
Should pass in repository ID instead
lf-jason-jia Sep 14, 2023
a6f667c
Update task cancellation usage
lf-jason-jia Sep 15, 2023
ad08f89
We already check equality using Linq
lf-jason-jia Sep 15, 2023
5a6bdb5
Update task cancellation test since the original test no longer fits …
lf-jason-jia Sep 15, 2023
35319b1
There's no server session anymore, so remove its tests
lf-jason-jia Sep 15, 2023
838b475
There's no point unit testing auto generated implementation
lf-jason-jia Sep 15, 2023
06324ab
Remove tests since related class no longer exists
lf-jason-jia Sep 15, 2023
20c3a21
Again, let's no to test auto-generated implementation
lf-jason-jia Sep 15, 2023
6295858
Remove unused import
lf-jason-jia Sep 15, 2023
bea808b
Remove tests since CreateEntryResult no longer exists
lf-jason-jia Sep 15, 2023
d38da1d
Remove the test since it's testing .NET HTTP client
lf-jason-jia Sep 15, 2023
3321fff
Use the repository that other client libraries use
lf-jason-jia Sep 15, 2023
4032034
Do not run on production
lf-jason-jia Sep 15, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 1 addition & 13 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,24 +39,12 @@ jobs:
env:
ACCESS_KEY: ${{ secrets.DEV_CA_PUBLIC_USE_INTEGRATION_TEST_ACCESS_KEY }}
SERVICE_PRINCIPAL_KEY: ${{ secrets.DEV_CA_PUBLIC_USE_TESTOAUTHSERVICEPRINCIPAL_SERVICE_PRINCIPAL_KEY }}
REPOSITORY_ID: ${{ secrets.DEV_CA_PUBLIC_USE_REPOSITORY_ID_3 }}
REPOSITORY_ID: ${{ secrets.DEV_CA_PUBLIC_USE_REPOSITORY_ID_1 }}
AUTHORIZATION_TYPE: ${{ secrets.AUTHORIZATION_TYPE }}
TEST_HEADER: ${{ secrets.TEST_HEADER }}
run:
dotnet test tests/integration/Laserfiche.Repository.Api.Client.IntegrationTest.csproj --no-build --verbosity normal --logger "trx;LogFileName=integration-test-results.trx"

- name: Run integration tests on API Server
continue-on-error: true
env:
REPOSITORY_ID: ${{ secrets.APISERVER_REPOSITORY_ID }}
APISERVER_USERNAME: ${{ secrets.APISERVER_USERNAME }}
APISERVER_PASSWORD: ${{ secrets.APISERVER_PASSWORD }}
APISERVER_REPOSITORY_API_BASE_URL: ${{ secrets.APISERVER_REPOSITORY_API_BASE_URL }}
AUTHORIZATION_TYPE: ${{ secrets.APISERVER_AUTHORIZATION_TYPE }}
TEST_HEADER: ${{ secrets.TEST_HEADER }}
run:
dotnet test tests/integration/Laserfiche.Repository.Api.Client.IntegrationTest.csproj --no-build --verbosity normal --logger "trx;LogFileName=integration-test-self-hosted-results.trx"

- name: Test Report
uses: dorny/test-reporter@v1
if: success() || failure() # run this step even if previous step failed
Expand Down
1 change: 1 addition & 0 deletions generate-client/nswag.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@
"generateOptionalParameters": true,
"generateUpdateJsonSerializerSettingsMethod": false,
"useBaseUrl": false,
"arrayType": "IList",
"templateDirectory": "nswag",
"wrapResponses": true,
"wrapResponseMethods": [
Expand Down
45 changes: 0 additions & 45 deletions generate-client/swagger-override.json
Original file line number Diff line number Diff line change
@@ -1,51 +1,6 @@
{
"components": {
"schemas": {
"PutFieldValsRequest": {
"allOf": [
{
"$ref": "#/components/schemas/SimpleImportMetadata"
},
{
"type": "object",
"description": "The request body containing fields that will be assigned to the entry.",
"additionalProperties": false,
"properties": {
"links": {
"type": "array",
"description": "The links that will be assigned to the entry.",
"nullable": true,
"items": {
"$ref": "#/components/schemas/LinkToUpdate"
}
}
}
}
]
},
"SimpleImportMetadata": {
"type": "object",
"additionalProperties": false,
"properties": {
"fields": {
"type": "object",
"description": "The fields that will be assigned to the entry.",
"nullable": true,
"additionalProperties": {
"$ref": "#/components/schemas/FieldToUpdate"
}
},
"tags": {
"type": "array",
"description": "The tags that will be assigned to the entry.",
"nullable": true,
"items": {
"type": "string"
}
}
}
},
"ImportAsyncMetadata": null
}
}
}
Loading
Loading