Fix unit test and cypress test
This commit is contained in:
parent
b0a57abaa8
commit
8d40c558f0
|
|
@ -1,21 +1,33 @@
|
||||||
describe('Instruments Page', () => {
|
describe('Instruments Page', () => {
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
cy.setup();
|
cy.setup();
|
||||||
|
const languageCategory = {
|
||||||
|
name: 'Sprache & Kommunikation',
|
||||||
|
id: 'LANGUAGE_COMMUNICATION',
|
||||||
|
foreground: '#000000',
|
||||||
|
background: '#00ffff'
|
||||||
|
};
|
||||||
|
const societyCategory = {
|
||||||
|
name: 'Gesellschaft',
|
||||||
|
id: 'SOCIETY',
|
||||||
|
foreground: '#ffffff',
|
||||||
|
background: '#000fff'
|
||||||
|
};
|
||||||
const analyse = {
|
const analyse = {
|
||||||
name: 'Analyse',
|
name: 'Analyse',
|
||||||
category: 'LANGUAGE_COMMUNICATION',
|
category: languageCategory,
|
||||||
type: 'analyse',
|
type: 'analyse',
|
||||||
};
|
};
|
||||||
|
|
||||||
const argumentation = {
|
const argumentation = {
|
||||||
name: 'Argumentation',
|
name: 'Argumentation',
|
||||||
category: 'LANGUAGE_COMMUNICATION',
|
category: languageCategory,
|
||||||
type: 'argumentation',
|
type: 'argumentation',
|
||||||
};
|
};
|
||||||
|
|
||||||
const ethik = {
|
const ethik = {
|
||||||
name: 'Ethik',
|
name: 'Ethik',
|
||||||
category: 'SOCIETY',
|
category: societyCategory,
|
||||||
type: 'ethik',
|
type: 'ethik',
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
@ -47,13 +59,13 @@ describe('Instruments Page', () => {
|
||||||
argumentation,
|
argumentation,
|
||||||
{
|
{
|
||||||
name: 'Beschreibung',
|
name: 'Beschreibung',
|
||||||
category: 'LANGUAGE_COMMUNICATION',
|
category: languageCategory,
|
||||||
type: 'beschreibung',
|
type: 'beschreibung',
|
||||||
},
|
},
|
||||||
ethik,
|
ethik,
|
||||||
{
|
{
|
||||||
name: 'Identität und Sozialisation',
|
name: 'Identität und Sozialisation',
|
||||||
category: 'SOCIETY',
|
category: societyCategory,
|
||||||
type: 'identitt-und-sozialisation',
|
type: 'identitt-und-sozialisation',
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
|
|
||||||
|
|
@ -16,9 +16,9 @@ from users.models import User
|
||||||
from users.services import create_users
|
from users.services import create_users
|
||||||
|
|
||||||
|
|
||||||
class MyAssignemntsText(DefaultUserTestCase):
|
class MyAssignmentsTest(DefaultUserTestCase):
|
||||||
def setUp(self):
|
def setUp(self):
|
||||||
super(MyAssignemntsText, self).setUp()
|
super(MyAssignmentsTest, self).setUp()
|
||||||
self.assignment = AssignmentFactory(
|
self.assignment = AssignmentFactory(
|
||||||
owner=self.teacher
|
owner=self.teacher
|
||||||
)
|
)
|
||||||
|
|
@ -119,7 +119,10 @@ class MyAssignemntsText(DefaultUserTestCase):
|
||||||
type {
|
type {
|
||||||
id
|
id
|
||||||
type
|
type
|
||||||
category
|
category {
|
||||||
|
id
|
||||||
|
name
|
||||||
|
}
|
||||||
}
|
}
|
||||||
slug
|
slug
|
||||||
bookmarks {
|
bookmarks {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue