Subversion Repository Public Repository

ConnectionOdbcSdk

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
´╗┐using System;
using System.Threading;
using Cisco.UnityConnection.OdbcSdk;
using ConnectionServerOdbcIntegrationTests.Properties;
using Microsoft.VisualStudio.TestTools.UnitTesting;


namespace UnityConnectionServerOdbcTests
{
    public abstract class BaseIntegrationTests
    {
        // ReSharper does not handle the Assert. calls in unit test property - turn off checking for unreachable code
        // ReSharper disable HeuristicUnreachableCode

        #region Fields and Properties

        //class wide instance of a ConnectionServer object used for all tests - this is attached to in the class initialize
        //routine below.
        public static UnityConnectionServerOdbcSdk Server { get; set; }

        /// <summary>
        ///Gets or sets the test context which provides
        ///information about and functionality for the current test run.
        ///</summary>
        public TestContext TestContext { get; set; }

        #endregion


        #region Additional test attributes
        // 
        //Use ClassInitialize to run code before running the first test in the class
        [ClassInitialize]
        public static void MyClassInitialize(TestContext testContext)
        {
            //create a connection server instance used for all tests - rather than using a mockup 
            //for fetching data I prefer this "real" testing approach using a public server I keep up
            //and available for the purpose - the conneciton information is stored in the test project's 
            //settings and can be changed to a local instance easily.
            Settings mySettings = new Settings();
            Thread.Sleep(300);
            try
            {
                Server = new UnityConnectionServerOdbcSdk("testing");
                Server.LoginDatabaseBlocking(mySettings.ConnectionServer,mySettings.ConnectionLogin, mySettings.ConnectionPW);
            }
            catch (Exception ex)
            {
                throw new Exception("Unable to attach to Connection server to start tests:" + ex.Message);
            }
        }

        #endregion
    }
}

Commits for ConnectionOdbcSdk/trunk/ConnectionServerOdbcIntegrationTests/IntegrationTests/BaseIntegrationTests.cs

Diff revisions: vs.
Revision Author Commited Message
29 Diff Diff jlindborg picture jlindborg Thu 28 Aug, 2014 01:11:13 +0000

updating integration tests for project

21 Diff Diff jlindborg picture jlindborg Wed 08 Jan, 2014 01:22:54 +0000

Final rework of framework – simplified class structure to remove seperate DBFunctions reference and have all items under the UnityConnectionServerOdbcSdk service which uses pass through calls to the DB specific methods so clients have just a single class instance to deal with.

20 Diff Diff jlindborg picture jlindborg Tue 07 Jan, 2014 03:22:54 +0000

Finished basic reorg of interface/class structure to optimize for unit test construction.

19 Diff Diff jlindborg picture jlindborg Mon 06 Jan, 2014 22:26:38 +0000

renaming and reorganizing unit tests a bit.

15 Diff Diff jlindborg picture jlindborg Sun 08 Sep, 2013 17:27:35 +0000

2.0.3
Changed class name to be CiscoUnityConnectionServerOdbc
Updated to support 32 or 64 bit projects
Changed order of parameters on login methods at server and DB functions class to match.
Started testing for NuGet package deployment.
Dropped in holder for dev guide docs

10 Diff Diff jlindborg picture jlindborg Mon 02 Sep, 2013 18:54:54 +0000

More unit and integration test work

8 jlindborg picture jlindborg Fri 30 Aug, 2013 00:27:58 +0000

adding some unit/integration tests into the project, doing a little cleanup.