If downgrading from 101 to 100, it'd try to delete version 100
from the database.
Revision history for {{$dist->name}}
{{$NEXT}}
+ - Stop deleting the wrong version
- Fix documentation for in the Cookbook (moltar)
0.001005 2011-04-13 15:21:08 CST6CDT
}
sub downgrade {
- log_info { 'upgrading' };
+ log_info { 'downgrading' };
my $self = shift;
my $ran_once = 0;
while ( my $version_list = $self->previous_version_set ) {
$self->downgrade_single_step({ version_set => $version_list });
# do we just delete a row here? I think so but not sure
- $self->delete_database_version({ version => $version_list->[-1] });
+ $self->delete_database_version({ version => $version_list->[0] });
}
log_warn { 'no version to run downgrade' } unless $ran_once;
}
baz => 'frew',
})
} 'schema is at version 2';
+
+ is $handler->version_storage->database_version => 2,
+ 'database version is down to 2';
+
}
done_testing;