Supprimer 'scotests/test_edit.py'

This commit is contained in:
Fares Amer 2021-06-10 16:06:15 +02:00
parent 2c7d55713a
commit 11618196b3
1 changed files with 0 additions and 46 deletions

View File

@ -1,46 +0,0 @@
# -*- mode: python -*-
# -*- coding: utf-8 -
import random
# La variable context est définie par le script de lancement
# l'affecte ainsi pour évietr les warnins pylint:
context = context # pylint: disable=undefined-variable
REQUEST = REQUEST # pylint: disable=undefined-variable
import scotests.sco_fake_gen as sco_fake_gen # pylint: disable=import-error
G = sco_fake_gen.ScoFake(context.Notes)
G.verbose = False
# --- Création d'une formation
f = G.create_formation(acronyme="")
ue = G.create_ue(formation_id=f["formation_id"], acronyme="TST1", titre="ue test")
mat = G.create_matiere(ue_id=ue["ue_id"], titre="matière test")
mod = G.create_module(
matiere_id=mat["matiere_id"],
code="TSM1",
coefficient=1.0,
titre="module test",
ue_id=ue["ue_id"], # faiblesse de l'API
formation_id=f["formation_id"], # faiblesse de l'API
)
# --- Mise place d'un semestre
sem = G.create_formsemestre(
formation_id=f["formation_id"],
semestre_id=1,
date_debut="01/01/2021",
date_fin="30/06/2021",
)
mi = G.create_moduleimpl(
module_id=mod["module_id"],
formsemestre_id=sem["formsemestre_id"],
responsable_id="bach",
)
# --- Modification d'un module
context.Notes.do_module_edit({"module_id":mod["module_id"], "code": "MOD1", "titre" : "module modifie"})
print(mod)