rpms/python-migrate/devel python-migrate-disable-test_fk.patch, NONE, 1.1 python-migrate-unittests.patch, NONE, 1.1 .cvsignore, 1.3, 1.4 python-migrate-sqlalchemy-migrate.patch, 1.1, 1.2 python-migrate.spec, 1.6, 1.7 sources, 1.3, 1.4 python-migrate-disable-pytest.patch, 1.1, NONE python-migrate-migrate_repository.patch, 1.1, NONE
Toshio くらとみ
toshio at fedoraproject.org
Wed Jan 28 01:51:30 UTC 2009
Author: toshio
Update of /cvs/pkgs/rpms/python-migrate/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv20441
Modified Files:
.cvsignore python-migrate-sqlalchemy-migrate.patch
python-migrate.spec sources
Added Files:
python-migrate-disable-test_fk.patch
python-migrate-unittests.patch
Removed Files:
python-migrate-disable-pytest.patch
python-migrate-migrate_repository.patch
Log Message:
* Mon Jan 26 2009 Toshio Kuratomi <toshio at fedoraproject.org> 0.5.1-0.1.20090122.svn479
- Update to snapshot so that it works with sqlalchemy-0.5
- Enable test suite
python-migrate-disable-test_fk.patch:
--- NEW FILE python-migrate-disable-test_fk.patch ---
diff -up sqlalchemy-migrate-0.5.1.dev-r479/test/changeset/test_changeset.py.bak sqlalchemy-migrate-0.5.1.dev-r479/test/changeset/test_changeset.py
--- sqlalchemy-migrate-0.5.1.dev-r479/test/changeset/test_changeset.py.bak 2009-01-26 17:42:59.000000000 -0800
+++ sqlalchemy-migrate-0.5.1.dev-r479/test/changeset/test_changeset.py 2009-01-26 17:43:34.000000000 -0800
@@ -150,26 +150,26 @@ class TestAddDropColumn(fixture.DB):
return drop_column(col.name,self.table)
return self.run_(add_func,drop_func)
- @fixture.usedb()
- def test_fk(self):
- """Can create columns with foreign keys"""
- reftable = Table('tmp_ref',self.meta,
- Column('id',Integer,primary_key=True),
- )
- # create FK's target
- if self.engine.has_table(reftable.name):
- reftable.drop()
- reftable.create()
- def add_func(col):
- self.table.append_column(col)
- return create_column(col.name,self.table)
- def drop_func(col):
- ret = drop_column(col.name,self.table)
- if self.engine.has_table(reftable.name):
- reftable.drop()
- return ret
- return self.run_(add_func,drop_func,Integer,
- ForeignKey(reftable.c.id))
+ #@fixture.usedb()
+ #def test_fk(self):
+ # """Can create columns with foreign keys"""
+ # reftable = Table('tmp_ref',self.meta,
+ # Column('id',Integer,primary_key=True),
+ # )
+ # # create FK's target
+ # if self.engine.has_table(reftable.name):
+ # reftable.drop()
+ # reftable.create()
+ # def add_func(col):
+ # self.table.append_column(col)
+ # return create_column(col.name,self.table)
+ # def drop_func(col):
+ # ret = drop_column(col.name,self.table)
+ # if self.engine.has_table(reftable.name):
+ # reftable.drop()
+ # return ret
+ # return self.run_(add_func,drop_func,Integer,
+ # ForeignKey(reftable.c.id))
#@fixture.usedb()
#def xtest_pk(self):
python-migrate-unittests.patch:
--- NEW FILE python-migrate-unittests.patch ---
Index: test/versioning/test_shell.py
===================================================================
--- test/versioning/test_shell.py (revision 479)
+++ test/versioning/test_shell.py (working copy)
@@ -1,6 +1,7 @@
import sys
import traceback
from StringIO import StringIO
+from types import FileType
import os,shutil
from test import fixture
from migrate.versioning.repository import Repository
@@ -19,7 +20,7 @@
def execute(self,shell_cmd,runshell=None):
"""A crude simulation of a shell command, to speed things up"""
# If we get an fd, the command is already done
- if isinstance(shell_cmd,file) or isinstance(shell_cmd,StringIO):
+ if isinstance(shell_cmd, FileType) or isinstance(shell_cmd, StringIO):
return shell_cmd
# Analyze the command; see if we can 'fake' the shell
try:
Index: .cvsignore
===================================================================
RCS file: /cvs/pkgs/rpms/python-migrate/devel/.cvsignore,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- .cvsignore 25 Jul 2008 05:22:43 -0000 1.3
+++ .cvsignore 28 Jan 2009 01:51:00 -0000 1.4
@@ -1 +1 @@
-sqlalchemy-migrate-0.4.5.tar.gz
+sqlalchemy-migrate-0.5.1.dev-r479.tar.gz
python-migrate-sqlalchemy-migrate.patch:
Index: python-migrate-sqlalchemy-migrate.patch
===================================================================
RCS file: /cvs/pkgs/rpms/python-migrate/devel/python-migrate-sqlalchemy-migrate.patch,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- python-migrate-sqlalchemy-migrate.patch 30 Jul 2008 04:32:59 -0000 1.1
+++ python-migrate-sqlalchemy-migrate.patch 28 Jan 2009 01:51:00 -0000 1.2
@@ -1,8 +1,8 @@
-Index: sqlalchemy-migrate-0.4.5/setup.py
+Index: sqlalchemy-migrate-0.5.1.dev-r479/setup.py
===================================================================
---- sqlalchemy-migrate-0.4.5.orig/setup.py
-+++ sqlalchemy-migrate-0.4.5/setup.py
-@@ -34,8 +34,8 @@ Migrate extends SQLAlchemy to have datab
+--- sqlalchemy-migrate-0.5.1.dev-r479.orig/setup.py
++++ sqlalchemy-migrate-0.5.1.dev-r479/setup.py
+@@ -31,8 +31,8 @@ Migrate extends SQLAlchemy to have datab
entry_points = """
[console_scripts]
@@ -11,5 +11,5 @@
+ sqlalchemy-migrate = migrate.versioning.shell:main
+ sqlalchemy-migrate-repository = migrate.versioning.migrate_repository:main
""",
- test_suite = "py.test.cmdline.main",
+ test_suite = "nose.collector",
)
Index: python-migrate.spec
===================================================================
RCS file: /cvs/pkgs/rpms/python-migrate/devel/python-migrate.spec,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- python-migrate.spec 29 Nov 2008 15:36:10 -0000 1.6
+++ python-migrate.spec 28 Jan 2009 01:51:00 -0000 1.7
@@ -3,27 +3,35 @@
%define srcname sqlalchemy-migrate
Name: python-migrate
-Version: 0.4.5
-Release: 4%{?dist}
+Version: 0.5.1
+Release: 0.1.20090122.svn479%{?dist}
Summary: Schema migration tools for SQLAlchemy
Group: Development/Languages
License: MIT
URL: http://code.google.com/p/%{srcname}/
-Source0: http://%{srcname}.googlecode.com/files/%{srcname}-%{version}.tar.gz
-# Local patch to disable py.test. Needed until py.test is in Fedora.
-Patch0: python-migrate-disable-pytest.patch
-# Patch sent upstream to generate a script for the repository upgrade script
-Patch1: python-migrate-migrate_repository.patch
+# Build from a snapshot so we get this working with sqlalchemy-0.5
+# svn checkout http://sqlalchemy-migrate.googlecode.com/svn/trunk/ sqlalchemy-migrate -r479
+# cd sqlalchemy-migrate
+# python setup.py sdist
+# tarball is in dist/sqlalchemy-migrate-0.5.1.dev-r479.tar.gz
+Source0: %{srcname}-%{version}.dev-r479.tar.gz
+#Source0: http://%{srcname}.googlecode.com/files/%{srcname}-%{version}.tar.gz
# Local patch to rename /usr/bin/migrate to sqlalchemy-migrate
-Patch2: python-migrate-sqlalchemy-migrate.patch
+Patch0: python-migrate-sqlalchemy-migrate.patch
+# Sent upstream to fix a unittest failure
+Patch1: python-migrate-unittests.patch
+# Disable one unittest for now. In the future we want this to work
+Patch2: python-migrate-disable-test_fk.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch
BuildRequires: python-devel
+BuildRequires: python-sqlalchemy
BuildRequires: python-setuptools-devel
-Requires: python-sqlalchemy >= 0.3.10
+BuildRequires: python-nose
+Requires: python-sqlalchemy >= 0.5
Requires: python-setuptools
%description
@@ -33,10 +41,11 @@
atabase change sets and database repository versioning.
%prep
-%setup -q -n %{srcname}-%{version}
-%patch0 -p1 -b .pytest
-%patch1 -p0 -b .repomigrate
-%patch2 -p1 -b .rename
+%setup -q -n %{srcname}-%{version}.dev-r479
+%patch0 -p1 -b .rename
+%patch1 -p0 -b .testing
+# Try removing this patch on every update
+%patch2 -p1 -b .disable-test
%build
%{__python} setup.py build
@@ -48,12 +57,9 @@
%clean
%{__rm} -rf %{buildroot}
-# Check needs py.test in order to run
-#%check
-#echo 'sqlite:///__tmp__' > test_db.cfg
-# setuptools doesn't appear to be compatible with py.test
-# %{__python} setup.py test
-#%{__python} -c 'from py.test.cmdline import main; main(["test"])'
+%check
+echo 'sqlite:///__tmp__' > test_db.cfg
+%{__python} setup.py test
%files
%defattr(-,root,root,-)
@@ -62,6 +68,10 @@
%{python_sitelib}/*
%changelog
+* Mon Jan 26 2009 Toshio Kuratomi <toshio at fedoraproject.org> 0.5.1-0.1.20090122.svn479
+- Update to snapshot so that it works with sqlalchemy-0.5
+- Enable test suite
+
* Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm at gmail.com> - 0.4.5-4
- Rebuild for Python 2.6
Index: sources
===================================================================
RCS file: /cvs/pkgs/rpms/python-migrate/devel/sources,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- sources 25 Jul 2008 05:22:43 -0000 1.3
+++ sources 28 Jan 2009 01:51:00 -0000 1.4
@@ -1 +1 @@
-d4f17e2c7fcfbb7bd0df628d974c8e3e sqlalchemy-migrate-0.4.5.tar.gz
+bff7f5c013497fdc7c2f79e48b6a38ad sqlalchemy-migrate-0.5.1.dev-r479.tar.gz
--- python-migrate-disable-pytest.patch DELETED ---
--- python-migrate-migrate_repository.patch DELETED ---
More information about the fedora-extras-commits
mailing list