test for excellent connection
[linksys-wrt3g-tools.git] / tests / index_wstatus1-connected-excellent.phpt
diff --git a/tests/index_wstatus1-connected-excellent.phpt b/tests/index_wstatus1-connected-excellent.phpt
new file mode 100644 (file)
index 0000000..363a940
--- /dev/null
@@ -0,0 +1,21 @@
+--TEST--
+test Wrt3g_HtmlParser::index_wstatus1() when we have an excellent connection
+--FILE--
+<?php
+chdir(dirname(__FILE__));
+require_once dirname(__FILE__) . '/../Wrt3g/HtmlParser.php';
+$p = new Wrt3g_HtmlParser();
+var_dump(
+    $p->index_wstatus1(
+        file_get_contents('index_wstatus1-connected-excellent.htm')
+    )
+);
+--EXPECT--
+array(3) {
+  ["type"]=>
+  string(8) "GPRS"
+  ["network"]=>
+  string(8) "BASE DE"
+  ["signal strength"]=>
+  string(8) "excellent"
+}