Program: 34935
Project: 34935
Buggy source:
@Test public void processBeanIdentityStoreHandlerStaysTrueIdentityStoreStaysTrue(){
  final Set<Type> types=new HashSet<Type>();
  types.add(new TypeLiteral<Bean>(){
  }
.getType());
  types.add(new TypeLiteral<IdentityStoreHandler>(){
  }
.getType());
  final Set<Type> types2=new HashSet<Type>();
  types2.add(new TypeLiteral<Bean>(){
  }
.getType());
  types2.add(new TypeLiteral<IdentityStore>(){
  }
.getType());
  context.checking(new Expectations(){
{
      exactly(2).of(pb).getBean();
      will(returnValue(bn));
      exactly(3).of(bn).getBeanClass();
      will(returnValue(Object.class));
      exactly(2).of(bn).getTypes();
      will(returnValue(types));
      one(pb2).getBean();
      will(returnValue(bn2));
      exactly(2).of(bn2).getBeanClass();
      will(returnValue(Object.class));
      one(bn2).getTypes();
      will(returnValue(types2));
      never(pb3).getBean();
    }
  }
);
  JavaEESecCDIExtension j3ce=new JavaEESecCDIExtension();
  assertFalse("String_Node_Str",j3ce.getIdentityStoreHandlerRegistered());
  assertFalse("String_Node_Str",j3ce.getIdentityStoreRegistered());
  j3ce.processBean(pb,bm);
  assertTrue("String_Node_Str",j3ce.getIdentityStoreHandlerRegistered());
  assertFalse("String_Node_Str",j3ce.getIdentityStoreRegistered());
  j3ce.processBean(pb2,bm);
  assertTrue("String_Node_Str",j3ce.getIdentityStoreHandlerRegistered());
  assertTrue("String_Node_Str",j3ce.getIdentityStoreRegistered());
  j3ce.processBean(pb3,bm);
  assertTrue("String_Node_Str",j3ce.getIdentityStoreHandlerRegistered());
  assertTrue("String_Node_Str",j3ce.getIdentityStoreRegistered());
}

Fixed version (ground truth):
@Test public void processBeanIdentityStoreHandlerStaysTrueIdentityStoreStaysTrue(){
  final Set<Type> types=new HashSet<Type>();
  types.add(new TypeLiteral<Bean>(){
  }
.getType());
  types.add(new TypeLiteral<IdentityStoreHandler>(){
  }
.getType());
  final Set<Type> types2=new HashSet<Type>();
  types2.add(new TypeLiteral<Bean>(){
  }
.getType());
  types2.add(new TypeLiteral<IdentityStore>(){
  }
.getType());
  context.checking(new Expectations(){
{
      exactly(2).of(pb).getBean();
      will(returnValue(bn));
      between(2,3).of(bn).getBeanClass();
      will(returnValue(Object.class));
      exactly(2).of(bn).getTypes();
      will(returnValue(types));
      one(pb2).getBean();
      will(returnValue(bn2));
      exactly(2).of(bn2).getBeanClass();
      will(returnValue(Object.class));
      one(bn2).getTypes();
      will(returnValue(types2));
      never(pb3).getBean();
    }
  }
);
  JavaEESecCDIExtension j3ce=new JavaEESecCDIExtension();
  assertFalse("String_Node_Str",j3ce.getIdentityStoreHandlerRegistered());
  assertFalse("String_Node_Str",j3ce.getIdentityStoreRegistered());
  j3ce.processBean(pb,bm);
  assertTrue("String_Node_Str",j3ce.getIdentityStoreHandlerRegistered());
  assertFalse("String_Node_Str",j3ce.getIdentityStoreRegistered());
  j3ce.processBean(pb2,bm);
  assertTrue("String_Node_Str",j3ce.getIdentityStoreHandlerRegistered());
  assertTrue("String_Node_Str",j3ce.getIdentityStoreRegistered());
  j3ce.processBean(pb3,bm);
  assertTrue("String_Node_Str",j3ce.getIdentityStoreHandlerRegistered());
  assertTrue("String_Node_Str",j3ce.getIdentityStoreRegistered());
}