ContainerHostEntity extends AbstractSubutaiHost implements ContainerHost { @Override public void setQuota( final ContainerQuota containerQuota ) throws PeerException { this.containerSize = containerQuota.getContainerSize(); getPeer().setQuota( this.getContainerId(), containerQuota ); } protected  ContainerHostEntity();  ContainerHostEntity( final String peerId, final String hostId, final String hostname,
                                HostArchitecture architecture, HostInterfaces hostInterfaces,
                                final String containerName, final String templateId, final String environmentId,
                                final String ownerId, final String initiatorPeerId, final ContainerQuota containerQuota,
                                final Integer vlan ); @Override Integer getVlan(); @Override String getEnvId(); @Override HostId getResourceHostId(); @Override String getContainerName(); @Override Quota getRawQuota(); @Override EnvironmentId getEnvironmentId(); @Override String getInitiatorPeerId(); @Override String getOwnerId(); @Override Peer getPeer(); @Override boolean isLocal(); @Override ContainerHostState getState(); ResourceHost getParent(); void setParent( final ResourceHost parent ); @Override String getTemplateName(); @Override String getTemplateId(); @Override Template getTemplate(); @Override void start(); @Override void stop(); @Override Snapshots listSnapshots(); @Override void removeSnapshot( final String partition, final String label ); @Override void rollbackToSnapshot( final String partition, final String label, final boolean force ); @Override void addSnapshot( final String partition, final String label, final boolean stopContainer ); @Override void updateHostInfo( final HostInfo hostInfo ); @Override HostInterfaces getHostInterfaces(); @Override HostInterface getInterfaceByName( final String interfaceName ); @Override ContainerQuota getQuota(); @Override void setQuota( final ContainerQuota containerQuota ); @Override ContainerSize getContainerSize(); @Override void setContainerSize( final ContainerSize containerSize ); @Override boolean isConnected(); @Override ContainerId getContainerId(); @Override String getLinkId(); @Override String getUniqueIdentifier(); @Override String getClassPath(); @Override String getContext(); @Override String getKeyId(); @Override String getIp(); @Override long getCreationTimestamp();  }
@Test public void testSetQuota() throws Exception { ContainerQuota ramQuota = mock( ContainerQuota.class ); containerHostEntity.setQuota( ramQuota ); verify( peer ).setQuota( containerHostEntity.getContainerId(), ramQuota ); }