diff --git a/projects/cobbler-api/src/lib/cobbler-api.service.spec.ts b/projects/cobbler-api/src/lib/cobbler-api.service.spec.ts
index 1c413839..8016501f 100644
--- a/projects/cobbler-api/src/lib/cobbler-api.service.spec.ts
+++ b/projects/cobbler-api/src/lib/cobbler-api.service.spec.ts
@@ -133,9 +133,15 @@ describe('CobblerApiService', () => {
expect(service).toBeFalsy();
});
- xit('should execute the background_signature_update action on the Cobbler Server', () => {
- service.background_signature_update('');
- expect(service).toBeFalsy();
+ it('should execute the background_signature_update action on the Cobbler Server', () => {
+ // eslint-disable-next-line max-len
+ const methodResponse = `2022-09-30_195846_Updating Signatures_6c5300d51c224984b4319fb536cc21d0`
+ const result = "2022-09-30_195846_Updating Signatures_6c5300d51c224984b4319fb536cc21d0"
+ service.background_signature_update('').subscribe(value => {
+ expect(value).toEqual(result)
+ });
+ const mockRequest = httpTestingController.expectOne('http://localhost/cobbler_api');
+ mockRequest.flush(methodResponse);
});
it('should execute the get_events action on the Cobbler Server', () => {
diff --git a/projects/cobbler-api/src/lib/cobbler-api.service.ts b/projects/cobbler-api/src/lib/cobbler-api.service.ts
index 41bd9865..e13cfab5 100644
--- a/projects/cobbler-api/src/lib/cobbler-api.service.ts
+++ b/projects/cobbler-api/src/lib/cobbler-api.service.ts
@@ -21,6 +21,7 @@ import {
SyncSystemsOptions,
Version
} from './custom-types/misc';
+import {DistroSignatures} from "./custom-types/signatures";
// TODO: Investigate on server side to build and receive well known interfaces, not just plain objects.
@@ -307,8 +308,9 @@ export class CobblerApiService {
}
background_signature_update(token: string): Observable {
+ const signatureUpdateOptions: XmlRpcStruct = {members: []}
return this.client
- .methodCall('background_signature_update', [token])
+ .methodCall('background_signature_update', [signatureUpdateOptions, token])
.pipe(
map((data: MethodResponse | MethodFault) => {
if (AngularXmlrpcService.instanceOfMethodResponse(data)) {
@@ -2128,17 +2130,54 @@ export class CobblerApiService {
);
}
- get_signatures(token: string): Observable