Skip to content
Snippets Groups Projects
Commit fc55cb6d authored by llaffont's avatar llaffont
Browse files

Correction import abonnés cosmogramme en ascii tabulé Orphée

parent 18abc265
Branches
Tags
No related merge requests found
......@@ -80,7 +80,7 @@ class abonne
}
$this->importFicheArray($enreg);
$this->importFicheArray(array_filter($enreg));
}
......
......@@ -100,6 +100,82 @@ class AbonneIntegrationASCIIWithNoUsersInDbTest extends AbonneIntegrationASCIITe
class AbonneIntegrationTabbedASCIIWithNoUsersInDbTest extends AbonneIntegrationASCIITestCase {
public function setup(){
parent::setup();
$this->abon_config->setChamps(['NULL',
'IDABON',
'NOM',
'PRENOM',
'NAISSANCE',
'DATE_FIN',
'NUM_CARTE',
'PASSWORD',
'NULL',
'NULL',
'NULL',
'NULL',
'NULL',
'NULL',
'NULL',
'NULL',
'NULL',
'MAIL']);
$this->abon_config->importFicheAscii('A 50 ANIMATION JEUNESSE 24/11/2013 50 jsecret8 5 14 10 1');
$this->user = Class_Users::getFirstAttributeForLastCallOn('save');
}
/** @test **/
public function abonneSigbMailShouldNotBeNull() {
$this->assertNotNull($this->user->getMail());
}
/** @test **/
public function idAbonShouldNotBe50() {
$this->assertEquals(50, $this->user->getIdabon());
}
/** @test */
public function nomShouldBeAnimationJeunesse() {
$this->assertEquals('ANIMATION JEUNESSE', $this->user->getNom());
}
/** @test */
public function prenomShouldBeEmptyString() {
$this->assertSame('', $this->user->getPrenom());
}
/** @test */
public function naissanceShouldBeEmptyString() {
$this->assertSame('', $this->user->getNaissance());
}
/** @test */
public function dateFinShouldBe2013_11_24() {
$this->assertEquals('2013-11-24', $this->user->getDateFin());
}
/** @test */
public function loginShould50() {
$this->assertEquals('50', $this->user->getLogin());
}
/** @test */
public function passwordShouldBejsecret8() {
$this->assertEquals('jsecret8', $this->user->getPassword());
}
}
class AbonneIntegrationASCIIWithRoutoInDbTest extends AbonneIntegrationTestCase {
protected $user_routo;
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment