/frameworks/solar/1.1.1/source/solar/tests/Test/Solar/Http/Request/Adapter/Curl.php

https://github.com/ggunlugu/ornekler · PHP · 318 lines · 119 code · 32 blank · 167 comment · 0 complexity · 7e63a82cd68d085836091f8e124ada82 MD5 · raw file

  1. <?php
  2. /**
  3. * Parent test.
  4. */
  5. require_once dirname(dirname(__FILE__)) . DIRECTORY_SEPARATOR . 'Adapter.php';
  6. /**
  7. *
  8. * Adapter class test.
  9. *
  10. */
  11. class Test_Solar_Http_Request_Adapter_Curl extends Test_Solar_Http_Request_Adapter {
  12. /**
  13. *
  14. * Configuration values.
  15. *
  16. * @var array
  17. *
  18. */
  19. protected $_Test_Solar_Http_Request_Adapter_Curl = array(
  20. );
  21. // -----------------------------------------------------------------
  22. //
  23. // Support methods.
  24. //
  25. // -----------------------------------------------------------------
  26. /**
  27. *
  28. * Constructor.
  29. *
  30. * @param array $config User-defined configuration parameters.
  31. *
  32. */
  33. public function __construct($config = null)
  34. {
  35. $this->todo('need adapter-specific config');
  36. }
  37. // -----------------------------------------------------------------
  38. //
  39. // Test methods.
  40. //
  41. // -----------------------------------------------------------------
  42. /**
  43. *
  44. * Test -- Constructor.
  45. *
  46. */
  47. public function test__construct()
  48. {
  49. $obj = Solar::factory('Solar_Http_Request_Adapter_Curl');
  50. $this->assertInstance($obj, 'Solar_Http_Request_Adapter_Curl');
  51. }
  52. /**
  53. *
  54. * Test -- Returns this object as a string; effectively, the request message to be sent.
  55. *
  56. */
  57. public function test__toString()
  58. {
  59. $this->todo('stub');
  60. }
  61. /**
  62. *
  63. * Test -- Fetches the last Solar_Http_Response object from the specified URI.
  64. *
  65. */
  66. public function testFetch()
  67. {
  68. $this->todo('stub');
  69. }
  70. /**
  71. *
  72. * Test -- Fetches all Solar_Http_Response objects from the specified URI (this includes all intervening redirects).
  73. *
  74. */
  75. public function testFetchAll()
  76. {
  77. $this->todo('stub');
  78. }
  79. /**
  80. *
  81. * Test -- Fetches from the specified URI and returns the response message as a string.
  82. *
  83. */
  84. public function testFetchRaw()
  85. {
  86. $this->todo('stub');
  87. }
  88. /**
  89. *
  90. * Test -- Returns the body content.
  91. *
  92. */
  93. public function testGetContent()
  94. {
  95. $this->todo('stub');
  96. }
  97. /**
  98. *
  99. * Test -- Returns all options as an array.
  100. *
  101. */
  102. public function testGetOptions()
  103. {
  104. $this->todo('stub');
  105. }
  106. /**
  107. *
  108. * Test -- Sets "Basic" authorization credentials.
  109. *
  110. */
  111. public function testSetBasicAuth()
  112. {
  113. $this->todo('stub');
  114. }
  115. /**
  116. *
  117. * Test -- Sets the character set for the body content.
  118. *
  119. */
  120. public function testSetCharset()
  121. {
  122. $this->todo('stub');
  123. }
  124. /**
  125. *
  126. * Test -- Sets the body content; technically you can use the public $content property, but this allows method-chaining.
  127. *
  128. */
  129. public function testSetContent()
  130. {
  131. $this->todo('stub');
  132. }
  133. /**
  134. *
  135. * Test -- Sets the content-type for the body content.
  136. *
  137. */
  138. public function testSetContentType()
  139. {
  140. $this->todo('stub');
  141. }
  142. /**
  143. *
  144. * Test -- Sets a cookie value in $this->_cookies to add to the request.
  145. *
  146. */
  147. public function testSetCookie()
  148. {
  149. $this->todo('stub');
  150. }
  151. /**
  152. *
  153. * Test -- Sets multiple cookie values in $this->_cookies to add to the request.
  154. *
  155. */
  156. public function testSetCookies()
  157. {
  158. $this->todo('stub');
  159. }
  160. /**
  161. *
  162. * Test -- Sets a header value in $this->_headers for sending at fetch() time.
  163. *
  164. */
  165. public function testSetHeader()
  166. {
  167. $this->todo('stub');
  168. }
  169. /**
  170. *
  171. * Test -- When making the request, allow no more than this many redirects.
  172. *
  173. */
  174. public function testSetMaxRedirects()
  175. {
  176. $this->todo('stub');
  177. }
  178. /**
  179. *
  180. * Test -- Sets the HTTP method for the request (GET, POST, etc).
  181. *
  182. */
  183. public function testSetMethod()
  184. {
  185. $this->todo('stub');
  186. }
  187. /**
  188. *
  189. * Test -- Send all requests through this proxy server.
  190. *
  191. */
  192. public function testSetProxy()
  193. {
  194. $this->todo('stub');
  195. }
  196. /**
  197. *
  198. * Test -- Sets the referer for the request.
  199. *
  200. */
  201. public function testSetReferer()
  202. {
  203. $this->todo('stub');
  204. }
  205. /**
  206. *
  207. * Test -- Location of Certificate Authority file on local filesystem which should be used with the $_ssl_verify_peer option to authenticate the identity of the remote peer.
  208. *
  209. */
  210. public function testSetSslCafile()
  211. {
  212. $this->todo('stub');
  213. }
  214. /**
  215. *
  216. * Test -- If $_ssl_cafile is not specified or if the certificate is not found there, this directory path is searched for a suitable certificate.
  217. *
  218. */
  219. public function testSetSslCapath()
  220. {
  221. $this->todo('stub');
  222. }
  223. /**
  224. *
  225. * Test -- Path to local certificate file on filesystem.
  226. *
  227. */
  228. public function testSetSslLocalCert()
  229. {
  230. $this->todo('stub');
  231. }
  232. /**
  233. *
  234. * Test -- Passphrase with which the $_ssl_local_cert file was encoded.
  235. *
  236. */
  237. public function testSetSslPassphrase()
  238. {
  239. $this->todo('stub');
  240. }
  241. /**
  242. *
  243. * Test -- Require verification of SSL certificate used?
  244. *
  245. */
  246. public function testSetSslVerifyPeer()
  247. {
  248. $this->todo('stub');
  249. }
  250. /**
  251. *
  252. * Test -- Sets the request timeout in seconds.
  253. *
  254. */
  255. public function testSetTimeout()
  256. {
  257. $this->todo('stub');
  258. }
  259. /**
  260. *
  261. * Test -- Sets the URI for the request.
  262. *
  263. */
  264. public function testSetUri()
  265. {
  266. $this->todo('stub');
  267. }
  268. /**
  269. *
  270. * Test -- Sets the User-Agent for the request.
  271. *
  272. */
  273. public function testSetUserAgent()
  274. {
  275. $this->todo('stub');
  276. }
  277. /**
  278. *
  279. * Test -- Sets the HTTP protocol version for the request (1.0 or 1.1).
  280. *
  281. */
  282. public function testSetVersion()
  283. {
  284. $this->todo('stub');
  285. }
  286. }