cloudsim-plus-master/cloudsim-plus-master/cloudsim-plus/src/test/java/org/cloudsimplus/integrationtests/VmCreationFailureIntegrationTest.java
private void onHostAllocation(VmHostEventInfo evt) {
        numberOfHostAllocations++;
        Log.printFormattedLine("# Host %s allocated to Vm %s at time %3.0f",
                evt.getHost().getId(), evt.getVm().getId(), evt.getTime());
        if (scenario.getFirstHostFromFirstDatacenter().equals(evt.getHost())
                && scenario.getFirstVmFromFirstBroker().equals(evt.getVm())) {
            assertEquals(
                "Host wasn't allocated to Vm at the expected time",
                0, evt.getTime(), 0.2);
        }
    }
/**
     * A lambda function used by an {@link Vm#addOnHostAllocationListener(EventListener)}  }
     * that will be called every time a Host is
     * allocated to a given VM. It tries to assert that the Host 0 was allocated
     * to the Vm 0 at the expected time.
     *
     * @param evt
     */
A lambda function used by an  Vm#addOnHostAllocationListener(EventListener)  }
that will be called every time a Host is
allocated to a given VM. It tries to assert that the Host 0 was allocated
to the Vm 0 at the expected time.

@param evt
A lambda function used by an Vm#addOnHostAllocationListener ( EventListener ) } that will be called every time a Host is allocated to a given VM . It tries to assert that the Host 0 was allocated to the Vm 0 at the expected time . @param evt
private void onHostAllocation(VmHostEventInfo evt) {
        numberOfHostAllocations++;
        Log.printFormattedLine("# Host %s allocated to Vm %s at time %3.0f",
                evt.getHost().getId(), evt.getVm().getId(), evt.getTime());
        if (scenario.getFirstHostFromFirstDatacenter().equals(evt.getHost())
                && scenario.getFirstVmFromFirstBroker().equals(evt.getVm())) {
            assertEquals(
                "Host wasn't allocated to Vm at the expected time",
                0, evt.getTime(), 0.2);
        }
    }
private void onHostAllocation ( VmHostEventInfo evt ) { numberOfHostAllocations ++ ; Log . printFormattedLine ( "# Host %s allocated to Vm %s at time %3.0f" , evt . getHost ( ) . getId ( ) , evt . getVm ( ) . getId ( ) , evt . getTime ( ) ) ; if ( scenario . getFirstHostFromFirstDatacenter ( ) . equals ( evt . getHost ( ) ) && scenario . getFirstVmFromFirstBroker ( ) . equals ( evt . getVm ( ) ) ) { assertEquals ( "Host wasn't allocated to Vm at the expected time" , 0 , evt . getTime ( ) , 0.2 ) ; } }
A lambda function used by an {@link Vm#addOnHostAllocationListener(EventListener)}  }
 that will be called every time a Host is
 allocated to a given VM.
A lambda function used by an { @link Vm#addOnHostAllocationListener ( EventListener ) } } that will be called every time a Host is allocated to a given VM .