StatefulSession sessionBean1 = sessionHome.create("testPassivationBySize");
sessionBean1.method1("hello");
// Create a second bean to force passivation
StatefulSession sessionBean2 = sessionHome.create("testPassivationBySize2");
sessionBean2.method1("hello");
// Validate that sessionBean1 was passivated and activated
Thread.sleep(1000);
boolean passivated = sessionBean1.getWasPassivated();
assertTrue("sessionBean1 WasPassivated", passivated);