Mercurial > altnet-hispano
annotate Agendas/trunk/src/Agendas.Tests/Cruds/RequestEmulator.cs @ 202:a731086c0b28
Se soluciona ticket 174.
Además se agrega detalle del campo Hora y Duración cuando son obligatorios en Resources.
author | alabra |
---|---|
date | Sat, 20 Aug 2011 18:40:36 -0400 |
parents | 2d1adbaf0373 |
children |
rev | line source |
---|---|
137 | 1 using System; |
2 using NHibernate; | |
3 using NHibernate.Context; | |
4 | |
5 namespace AltNetHispano.Agendas.Tests.Cruds | |
6 { | |
7 public class RequestEmulator : IDisposable | |
8 { | |
9 private readonly ISession _session; | |
10 | |
11 public RequestEmulator(ISessionFactory sessionFactory) | |
12 { | |
13 _session = sessionFactory.OpenSession(); | |
14 CurrentSessionContext.Bind(_session); | |
15 } | |
16 | |
17 public void Dispose() | |
18 { | |
19 _session.Flush(); | |
20 _session.Close(); | |
21 } | |
22 } | |
23 } |