ia64/xen-unstable

view tools/xm-test/tests/create/15_create_smallmem_pos.py @ 9936:bef7f5fcf207

Second step toward a new network infrastructure, move XmConsole to be
in XenDomain. The devices we will add, like network, will need to run
console commands when a domain is started. So I have made console be
a part of domain object, which it's tied to anyway.

Signed-off-by: Daniel Stekloff <dsteklof@us.ibm.com>
author emellor@leeni.uk.xensource.com
date Thu May 04 14:22:17 2006 +0100 (2006-05-04)
parents a22ce69dd703
children fd5140c2854f
line source
1 #!/usr/bin/python
3 # Copyright (C) International Business Machines Corp., 2005
4 # Author: Dan Smith <danms@us.ibm.com>
6 from XmTestLib import *
8 # 32MBs is the default lower limit for creating domains, it should work
9 MEM = 32
11 domain = XmTestDomain(extraConfig={"memory": MEM,
12 "extra" :"mem=%iM" % MEM})
14 try:
15 console = domain.start()
16 except DomainError, e:
17 FAIL("Unable to start a domain with %i MB" % MEM)
19 try:
20 console.runCmd("ls")
21 except ConsoleError, e:
22 if e.reason == RUNAWAY:
23 FAIL("Bug #380: Starting a console with %i MB crashed the console daemon" % MEM)
24 else:
25 FAIL("Starting a console with %i MB failed: domain dies immediately!" % MEM)
27 domain.destroy()