On 05/03/2013 04:18 PM, Simon King wrote:
On Thu, May 2, 2013 at 11:43 PM, Paradox para...@pobox.com wrote:
CREATE TABLE user (lname string, fname string, email string,
unique(lname, fname) ON CONFLICT REPLACE);
This will allow me to add multiple rows with the same lname as long as
the fnames
I am trying to ensure that my table doesn't allow duplicate rows.
The table is defined (in SqlAlchemy 0.8):
class User(Base):
__tablename__ = 'user'
id = Column(Integer, primary_key=True)
lname = Column(String)
fname = Column(String)
email = Column(String)
When you say you created a setup fixture but it didn't work, what
didn't work exactly?
For example, if you just did something like this:
def setup():
engine = ...
Session = ...
session = Session()
...then that won't work because session is a local variable inside the
setup
On 04/23/2013 04:31 PM, Simon King wrote:
On Tue, Apr 23, 2013 at 6:54 AM, Paradox para...@pobox.com wrote:
I have a question related to sqlalchemy and testing, not sure if this is the
best place to ask so let me know if I am asking here in error.
I am trying to learn to write and run tests
I have a question related to sqlalchemy and testing, not sure if this is
the best place to ask so let me know if I am asking here in error.
I am trying to learn to write and run tests using py.test. Currently I
am working on a spreadsheet scrapper that gathers data from a directory
tree of