test(backend): Testen voor DatabaseLearningObjectProvider.getLearningObjectById toegevoegd.
This commit is contained in:
parent
fb2d293b57
commit
a3b995393b
7 changed files with 102 additions and 11 deletions
|
@ -0,0 +1,10 @@
|
|||
import {LearningObjectExample} from "./learning-object-example";
|
||||
import {LearningObject} from "../../../src/entities/content/learning-object.entity";
|
||||
|
||||
export function createExampleLearningObjectWithAttachments(example: LearningObjectExample): LearningObject {
|
||||
let learningObject = example.createLearningObject();
|
||||
for (let creationFn of Object.values(example.createAttachment)) {
|
||||
learningObject.attachments.push(creationFn(learningObject));
|
||||
}
|
||||
return learningObject;
|
||||
}
|
|
@ -41,10 +41,7 @@ const example: LearningObjectExample = {
|
|||
|
||||
let returnValue = new ReturnValue();
|
||||
returnValue.callbackUrl = "callback_url_example";
|
||||
returnValue.callbackSchema = `{
|
||||
att: "test",
|
||||
att2: "test2"
|
||||
}`;
|
||||
returnValue.callbackSchema = '{"att": "test", "att2": "test2"}';
|
||||
|
||||
learningObject.returnValue = returnValue;
|
||||
learningObject.available = true;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue