URLs changed to new plugin addressing scheme

svn:keywords set
fixed: shutdown - delay reboot/poweroff by some seconds to finish the web page before
added: format_fs - show link to umount in case of active device
added: new plugin "language_selection"
fixed: recently introduced syntax error in 'network'
added: "volume_props" mentions encryption support via "format_fs" (including link)
updated: plugin-interface.txt
fixed: broken test case for date plugin (caused by twill, I guess)
added: "partition" plugin - better handling of config partition
This commit is contained in:
lars 2006-11-06 06:17:22 +00:00
parent 7905fe7051
commit 80337411ae
49 changed files with 259 additions and 116 deletions

View file

@ -8,7 +8,7 @@
<?cs call:handle_messages() ?>
<?cs call:print_form_header("set_ip", "plugins/network") ?>
<?cs call:print_form_header("set_ip", "network") ?>
<p><label for="ip"><?cs var:html_escape(Lang.Plugins.network.Text.IP) ?>: </label>
<input class="ipnum" type="text" tabindex="1" name="ip1" size="3" id="ip"

View file

@ -84,11 +84,11 @@ class network(CryptoBoxPlugin.CryptoBoxPlugin):
args = [
root_action_plug.IFCONFIG_BIN,
root_action_plug.IFACE])
proc.wait()
(stdout, stderr) = proc.communicate()
(output, error) = proc.communicate()
if proc.returncode != 0: return (0,0,0,0)
## this regex matches the four numbers of the IP
match = re.search(u'inet [\w]+:(\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})\s',output)
match = re.search(u'inet [\w]+:(\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})\s', stdout)
if match:
## use the previously matched numbers
return tuple([int(e) for e in match.groups()])

View file

@ -8,11 +8,11 @@ class unittests(WebInterfaceTestClass.WebInterfaceTestClass):
'''change of network address'''
## the time module is necessary for the CHANGE_IP_DELAY
import time
self.register_auth(self.URL + "plugins/network")
self.cmd.go(self.URL + "plugins/network")
self.register_auth(self.URL + "network")
self.cmd.go(self.URL + "network")
## extract the current IP from the network plugin output
def getCurrentIP():
self.cmd.go(self.URL + "plugins/network")
self.cmd.go(self.URL + "network")
self.cmd.show()
self.cmd.find(u'Data.Status.Plugins.network=([0-9\.]*)$', "m")
return self.locals["__match__"]
@ -23,7 +23,7 @@ class unittests(WebInterfaceTestClass.WebInterfaceTestClass):
self.cmd.echo(origIPocts)
wrongIP = "192.168.123.321"
def setIP((ip1, ip2, ip3, ip4)):
self.cmd.go(self.URL + "plugins/network")
self.cmd.go(self.URL + "network")
self.cmd.formvalue("set_ip", "ip1", str(ip1))
self.cmd.formvalue("set_ip", "ip2", str(ip2))
self.cmd.formvalue("set_ip", "ip3", str(ip3))