Testing for memory usage or getting a process ID with applicationContext

Last edited on

Every application is started in an application context. Application contexts are accessible in test scripts and they offer a number of functions and properties, including usedMemory:

def main():
    # ...

    ctx = currentApplicationContext()

This will print the memory used by the current application and its process ID to the test log.

The application context functions and properties are documented in the Squish API section under Application Context .

Also see: