-
Notifications
You must be signed in to change notification settings - Fork 269
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
[MNT-24575] Added APIS and models folder information dialog #10460
base: develop
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing unit tests for this file
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are no unit tests for this entire file. Should I create one, and add the unit tests for only the new code?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@swapnil-verma-gl the same like above - it will be enough if you add unit tests only for your code which you added/changed. For old code we can write unit tests later
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added unit tests
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@swapnil-verma-gl I can't see tests for this file. Maybe you forgot to push that file. There should be file for tests for nodes.api.ts. See example for tags.api.ts where we have tests in file called tagApi.spec.ts
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this is still not addressed
Quality Gate passedIssues Measures |
|
||
import { TestBed } from '@angular/core/testing'; | ||
import { HttpClientTestingModule } from '@angular/common/http/testing'; | ||
import { AlfrescoApiService, AlfrescoApiServiceMock, NodesApiService } from '@alfresco/adf-content-services'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're in content-services library so importing parts of it from @alfresco/adf-content-services
is not correct
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this is still not addressed
/** | ||
* Initiate a new request to calculate folder size. | ||
* | ||
* **Note:** this endpoint is available in Alfresco 7.1 and newer versions. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wasn't it added in latest version? Does it also have backwards compatibility until 7.1?
/** | ||
* Gets the size of a folder. | ||
* | ||
* **Note:** this endpoint is available in Alfresco 7.1 and newer versions. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same question here
* @returns Folder details | ||
*/ | ||
getFolderSizeInfo(nodeId: string, jobId: string): Observable<SizeDetailsEntry> { | ||
return from(this.nodesApi.getFolderSizeInfo(nodeId, jobId)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What about handling some cases when the job is not done yet and user is trying to get the response? Are you planning to handle it here or rather in ACA when this will be called?
|
||
Initiate a new request to calculate folder size. | ||
|
||
> this endpoint is available in **Alfresco 7.1** and newer versions. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same question about compatibility here
|
||
Gets the size details of a folder | ||
|
||
> this endpoint is available in **Alfresco 7.1** and newer versions. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And here
@@ -1196,6 +1198,67 @@ nodesApi.updateNodeContent(`<nodeId>`, contentBodyUpdate, opts).then((data) => { | |||
console.log('API called successfully. Returned data: ' + data); | |||
}); | |||
``` | |||
## initiateFolderSizeCalculation | |||
|
|||
Initiate a new request to calculate folder size. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Initiate a new request to calculate folder size. | |
Initiates a new request to calculate folder size. |
Please check if the PR fulfills these requirements
What kind of change does this PR introduce? (check one with "x")
What is the current behaviour? (You can also link to an open issue here)
No APIs for folder information exist
What is the new behaviour?
Added APIs to new backend endpoints
Does this PR introduce a breaking change? (check one with "x")
If this PR contains a breaking change, please describe the impact and migration path for existing applications: ...
Other information:
https://hyland.atlassian.net/browse/MNT-24575