Commit ef6a0ba4 authored by Laurent's avatar Laurent

Merge branch 'stable' into hotline-master

Conflicts:
	VERSIONS
	cosmogramme/php/_init.php
	cosmogramme/sql/patch/patch_307.php
	library/startup.php
	tests/db/UpgradeDBTest.php
parents fbb6b84d b91196ed
- ticket #49000 : correction de l'import total: des exemplaires n'étaient pas supprimés
17/10/2016 - v7.7.8
- ticket #48424 : Les champs personnalisés de type "choix multiples" sur les articles génèrent correctement les facettes associées en résultat de recherche
......
<?php
error_reporting(E_ERROR | E_PARSE);
define("PATCH_LEVEL","309");
define("PATCH_LEVEL","310");
define("APPLI","cosmogramme");
define("COSMOPATH", "/var/www/html/vhosts/opac2/www/htdocs");
......
<?php
try {
$adapter = Zend_Db_Table_Abstract::getDefaultAdapter();
$adapter->query('alter table exemplaires modify column to_delete boolean not null default false');
} catch(Exception $e) {}
?>
......@@ -1054,6 +1054,8 @@ class UpgradeDB_308_Test extends UpgradeDBTestCase {
}
class UpgradeDB_309_Test extends UpgradeDBTestCase {
public function prepare() {
try {
......@@ -1067,4 +1069,30 @@ class UpgradeDB_309_Test extends UpgradeDBTestCase {
public function bibCSiteTableShouldHaveColumnLinkToProfilId() {
$this->assertFieldType('bib_c_site', 'link_to_profil_id', 'int(11) unsigned');
}
}
class UpgradeDB_310_Test extends UpgradeDBTestCase {
public function prepare() {
try {
$this->query('alter table exemplaires modify column to_delete boolean null default null')
->query('update exemplaires set to_delete null');
} catch(Exception $e) {
}
}
/** @test */
public function itemsTableShouldHaveColumnToDeleteNotNullable() {
$this->assertFieldType('exemplaires', 'to_delete', 'tinyint(1)');
}
/** @test */
public function itemsTableShouldNotHaveItemsWithDeleteNull() {
$items = $this->query('select * from exemplaires where to_delete is null')->fetch();
$this->assertEmpty($items);
}
}
\ No newline at end of file
Markdown is supported
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