| /branches/v2.0-betulales/scripts/modules/tests/Tests.php |
|---|
| 1053,29 → 1053,31 |
| private function testerEpitheteInfraSpSyntaxe() { |
| $noms_erreur = array(); |
| foreach ($this->noms as &$nom) { |
| if ($nom['epithete_infra_sp'] != '') { |
| $mots = explode(' ', $nom['epithete_infra_sp']); |
| $hybride_contient_abbreviation_infra_sp = false; |
| $formule_hybridite = (strpos($nom['epithete_infra_sp'], ' x ') !== false); |
| foreach ($mots as $mot) { |
| if($formule_hybridite && $this->verifierEstAbbreviationInfraSp($mot)) { |
| $hybride_contient_abbreviation_infra_sp = true; |
| if ($nom["rang"] != 450) { |
| if ($nom['epithete_infra_sp'] != '') { |
| $mots = explode(' ', $nom['epithete_infra_sp']); |
| $hybride_contient_abbreviation_infra_sp = false; |
| $formule_hybridite = (strpos($nom['epithete_infra_sp'], ' x ') !== false); |
| foreach ($mots as $mot) { |
| if($formule_hybridite && $this->verifierEstAbbreviationInfraSp($mot)) { |
| $hybride_contient_abbreviation_infra_sp = true; |
| } |
| $formule_hybridite_valide = $this->verifierEpitheteGenre($mot) || $this->verifierEpitheteSp($mot) || $hybride_contient_abbreviation_infra_sp; |
| if (!(preg_match('/^[+x]$/', $mot) || $this->verifierTypeEpithete($mot) || $this->verifierEpitheteSp($mot) || |
| $formule_hybridite_valide)) { |
| $epithete_traite = $this->repererEspace($nom['epithete_infra_sp']); |
| $noms_erreur[] = array($nom['num_nom'], $epithete_traite, $nom['exclure_taxref']); |
| $this->ajouterNumNomErreursTest($nom['num_nom']); |
| break; |
| } |
| } |
| $formule_hybridite_valide = $this->verifierEpitheteGenre($mot) || $this->verifierEpitheteSp($mot) || $hybride_contient_abbreviation_infra_sp; |
| if (!(preg_match('/^[+x]$/', $mot) || $this->verifierTypeEpithete($mot) || $this->verifierEpitheteSp($mot) || |
| $formule_hybridite_valide)) { |
| if($formule_hybridite && !$hybride_contient_abbreviation_infra_sp) { |
| $epithete_traite = $this->repererEspace($nom['epithete_infra_sp']); |
| $noms_erreur[] = array($nom['num_nom'], $epithete_traite, $nom['exclure_taxref']); |
| $this->ajouterNumNomErreursTest($nom['num_nom']); |
| break; |
| } |
| } |
| if($formule_hybridite && !$hybride_contient_abbreviation_infra_sp) { |
| $epithete_traite = $this->repererEspace($nom['epithete_infra_sp']); |
| $noms_erreur[] = array($nom['num_nom'], $epithete_traite, $nom['exclure_taxref']); |
| $this->ajouterNumNomErreursTest($nom['num_nom']); |
| } |
| } |
| } |
| return $noms_erreur; |
| 1687,6 → 1689,34 |
| /** |
| * Test #79 |
| */ |
| private function testerNomSupPourSynonyme() { |
| $noms_erreur = array(); |
| foreach ($this->noms as &$nom) { |
| if ($nom['num_nom_retenu'] = $nom['num_nom'] && $nom['num_nom_sup'] != '') { |
| $noms_erreur[] = array($nom['num_nom'], $nom['num_nom_sup'], $nom['exclure_taxref']); |
| $this->ajouterNumNomErreursTest($nom['num_nom']); |
| } |
| } |
| return $noms_erreur; |
| } |
| /** |
| * Test #80 |
| */ |
| private function testerExistenceNomSuperieur() { |
| $noms_erreur = array(); |
| foreach ($this->noms as &$nom) { |
| if ($nom['num_nom_sup'] != 0 && !isset($this->noms[$nom['num_nom_sup']])) { |
| $noms_erreur[] = array($nom['num_nom'], $nom['num_nom_sup'], $nom['exclure_taxref']); |
| $this->ajouterNumNomErreursTest($nom['num_nom']); |
| } |
| } |
| return $noms_erreur; |
| } |
| /** |
| * Test #81 |
| */ |
| private function testerExclureTaxRefPresence() { |
| $noms_erreur = array(); |
| foreach ($this->noms as &$nom) { |
| /branches/v2.0-betulales/scripts/modules/tests/configurations/tests.ini |
|---|
| 561,6 → 561,18 |
| entete = "num_nom, nom_francais" |
| title=";;0 = non, 1 = oui, 9 = indéterminée" |
| [79] |
| abr = "Nom Sup Pour Synonyme" |
| nom = "Classification -> uniquement pour les synonymes" |
| description = "Seuls les synonymes doivent posséder une valeur dans le champ num_nom_sup." |
| entete = "num_nom,num_tax_sup,Exclusion de Taxref" |
| title=";;0 = non, 1 = oui, 9 = indéterminée" |
| [80] |
| abr = "Existence Nom Superieur" |
| nom = "Classification -> existence du nom supérieur" |
| description = "Un nom supérieur doit être existant dans la base." |
| entete = "num_nom,num_nom_sup,Exclusion de Taxref" |
| title=";;0 = non, 1 = oui, 9 = indéterminée" |
| [81] |
| abr = "Exclure Tax Ref Presence" |
| nom = "exclure_taxref -> presence" |
| description = "Un nom retenu non-exclu de taxref doit contenir : |
| /branches/v2.0-betulales/configurations/referentiel_v4.4.ini |
|---|
| 15,7 → 15,7 |
| ; Noms des champs de la bdnt |
| champs = "num_nom,num_nom_retenu,num_tax_sup,rang,nom_sci,nom_supra_generique,genre,epithete_infra_generique,epithete_sp,type_epithete,epithete_infra_sp,cultivar_groupe,cultivar,nom_commercial,auteur,annee,biblio_origine,notes,nom_addendum,homonyme,num_type,num_basionyme,synonyme_proparte,synonyme_douteux,synonyme_mal_applique,synonyme_orthographique,orthographe_originelle,hybride_parent_01,hybride_parent_01_notes,hybride_parent_02,hybride_parent_02_notes,nom_francais,presence,statut_origine,statut_introduction,statut_culture,exclure_taxref" |
| ; Noms des champs de la bdnt partielles |
| champs_partiel = "num_nom,num_nom_retenu,num_tax_sup,nom_sci,auteur,annee,biblio_origine,nom_addendum,nom_francais,presence,cd_nom" |
| champs_partiel = "num_nom,num_nom_retenu,num_tax_sup,nom_sci,auteur,annee,biblio_origine,nom_addendum,nom_francais,presence,cd_nom,num_nom_sup" |
| ; Noms des champs du diff de la bdnt |
| champs_diff = "modification_type,modification_type_1,modification_type_2,modification_type_3" |
| ; Noms des champs Taxref |
| 98,7 → 98,7 |
| statut_culture=3, |
| exclure_taxref=3" |
| ; Valeurs numériques des rangs |
| rangs = "3,10,20,30,33,36,40,42,45,47,50,53,56,60,70,80,90,100,110,120,130,140,150,160,170,180,190,193,196,200,210,215,220,230,235,240,250,260,270,275,280,290,300,310,320,330,340,350,360,370,380,390,400,410,420,430,440" |
| rangs = "3,10,20,30,33,36,40,42,45,47,50,53,56,60,70,80,90,100,110,120,130,140,150,160,170,180,190,193,196,200,210,215,220,230,235,240,250,260,270,275,280,290,300,310,320,330,340,350,360,370,380,390,400,410,420,430,440,450" |
| ; Correspondance Rang BDNT/Taxref (Format : code_numerique_rang_bdnt:code_taxref) |
| rangs_bdnt_taxref = "3:DUMM,10:SPRG,20:KD,30:SSRG,33:IFRG,36:?,40:PH,42:SBPH,45:IFPH,47:?,50:DV,53:SBDV,56:?,60:SPCL,70:CLAD,80:CL,90:SBCL,100:IFCL,110:LEG,120:SPOR,130:COH,140:OR,150:SBOR,160:IFOR,170:SPFM,180:FM,190:SBFM,193:?,196:?,200:TR,210:SSTR,215:?,220:GN,230:SSGN,235:?,240:SC,250:SBSC,260:SER,270:SSER,275:?,280:AGES,290:ES,300:SMES,310:MES,320:SSES,330:?,340:VAR,350:SVAR,360:FO,370:SSFO,380:FOES,390:LIN,400:CLO,410:RACE,420:MO,430:AB,440:CAR" |
| ; Valeur numérique indiquant le rang du genre |
| 162,7 → 162,8 |
| 410=Race/prole, |
| 420=Morpha, |
| 430=Abberatio, |
| 440=Plantes cultivées (cultivars/groupe cultivar/convariété...)" |
| 440=Plantes cultivées (cultivars/groupe cultivar/convariété...), |
| 450=Ecophènes" |
| ; TOUTES LES LISTES séparées par | sont insérées dans la regexp suivante : /^(?:$liste)$/ VOUS DEVEZ SI NÉCESSAIRE |
| ; ANTISLASHER LES CARACTÈRES : . \ + * ? [ ^ ] $ ( ) { } = ! < > : - |
| 248,7 → 249,7 |
| -=Autre notion de culture, |
| A=Non cultivé" |
| ; Correspondance entre les codes de statut de Taxref et les champs et code de statut des BDNT (Format : code_taxref=nom_champ_bdnt:code_statut_bdnt) |
| statuts_bdnt_taxref = "P=presence:P,A=presence:A,D=presence:D,X=presence:E,B=presence:P-B,W=presence:E-W,F=presence:E-F,C=statut_origine:S-F,E=statut_origine:N-E,S=statut_origine:N-S,Z=statut_origine:E-Z,I=statut_introduction:I,J=statut_introduction:I-J,M=statut_introduction:I-M,Y=statut_introduction:E" |
| statuts_bdnt_taxref = "Q=presence:F,P=presence:P,A=presence:A,D=presence:S,D=presence:D,X=presence:E,B=presence:P-B,W=presence:E-W,F=presence:E-F,C=statut_origine:S-F,E=statut_origine:N-E,S=statut_origine:N-S,Z=statut_origine:E-Z,I=statut_introduction:I,J=statut_introduction:I-J,M=statut_introduction:I-M,Y=statut_introduction:E" |
| ; MÉTADONNÉES |
| ; Liste des domaines géographiques |
| /branches/v2.0-betulales |
|---|
| Property changes: |
| Modified: svn:mergeinfo |
| Merged /trunk:r363-365 |