forked from ezSQL/ezsql
/
ezSQL_mssqlTest.php
137 lines (121 loc) · 3.96 KB
/
ezSQL_mssqlTest.php
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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
<?php
require_once dirname(__FILE__) . '/../../../shared/ez_sql_core.php';
require_once dirname(__FILE__) . '/../../../mssql/ez_sql_mssql.php';
/**
* Test class for ezSQL_mssql.
* Desc..: MS SQL Server component (part of ezSQL databse abstraction library)
*
* @author Justin Vincent (jv@jvmultimedia.com)
* @author Stefanie Janine Stoelting (mail@stefanie-stoelting.de)
* @link http://twitter.com/justinvincent
* @name ezSQL_mssqlTest
* @package ezSQL
* @subpackage unitTests
* @license FREE / Donation (LGPL - You may do what you like with ezSQL - no exceptions.)
* @todo The connection to MS SQL Server is not tested by now. There might also
* be tests done for different versions of SQL Server
*
*/
class ezSQL_mssqlTest extends PHPUnit_Framework_TestCase {
/**
* @var ezSQL_mssql
*/
protected $object;
/**
* Sets up the fixture, for example, opens a network connection.
* This method is called before a test is executed.
*/
protected function setUp() {
$this->object = new ezSQL_mssql;
} // setUp
/**
* Tears down the fixture, for example, closes a network connection.
* This method is called after a test is executed.
*/
protected function tearDown() {
$this->object = null;
} // tearDown
/**
* @covers ezSQL_mssql::quick_connect
* @todo Implement testQuick_connect().
*/
public function testQuick_connect() {
// Remove the following lines when you implement this test.
$this->markTestIncomplete(
'This test has not been implemented yet.'
);
} // testQuick_connect
/**
* @covers ezSQL_mssql::connect
* @todo Implement testConnect().
*/
public function testConnect() {
// Remove the following lines when you implement this test.
$this->markTestIncomplete(
'This test has not been implemented yet.'
);
} // testConnect
/**
* @covers ezSQL_mssql::select
* @todo Implement testSelect().
*/
public function testSelect() {
// Remove the following lines when you implement this test.
$this->markTestIncomplete(
'This test has not been implemented yet.'
);
} // testSelect
/**
* @covers ezSQL_mssql::escape
*/
public function testEscape() {
$result = $this->object->escape("This is'nt escaped.");
$this->assertEquals("This is''nt escaped.", $result);
} // testEscape
/**
* @covers ezSQL_mssql::sysdate
*/
public function testSysdate() {
$this->assertEquals('getDate()', $this->object->sysdate());
} // testSysdate
/**
* @covers ezSQL_mssql::query
* @todo Implement testQuery().
*/
public function testQuery() {
// Remove the following lines when you implement this test.
$this->markTestIncomplete(
'This test has not been implemented yet.'
);
} // testQuery
/**
* @covers ezSQL_mssql::ConvertMySqlToMSSql
* @todo Implement testConvertMySqlToMSSql().
*/
public function testConvertMySqlToMSSql() {
// Remove the following lines when you implement this test.
$this->markTestIncomplete(
'This test has not been implemented yet.'
);
} // testConvert
/**
* @covers ezSQL_mssql::disconnect
* @todo Implement testDisconnect().
*/
public function testDisconnect() {
// Remove the following lines when you implement this test.
$this->markTestIncomplete(
'This test has not been implemented yet.'
);
} // testDisconnect
/**
* @covers ezSQL_mssql::getDBHost
* @todo Implement testGetDBHost().
*/
public function testGetDBHost() {
// Remove the following lines when you implement this test.
$this->markTestIncomplete(
'This test has not been implemented yet.'
);
} // testGetDBHost
} // ezSQL_mssqlTest