io.fabric8.openshift.api.model.AbstractImageAssert Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of assertions Show documentation
Show all versions of assertions Show documentation
A port of Kubernetes Assertions Library by Fabric8
package io.fabric8.openshift.api.model;
import org.assertj.core.api.AbstractAssert;
import org.assertj.core.api.Assertions;
import org.assertj.core.api.AssertFactory;
import com.stakater.kubernetes.assertions.NavigationListAssert;
import static org.assertj.core.api.Assertions.assertThat;
import static io.fabric8.kubernetes.assertions.internal.Assertions.assertThat;
/**
* Abstract base class for {@link Image} specific assertions - Generated by CustomAssertionGenerator.
*/
public abstract class AbstractImageAssert, A extends Image> extends AbstractAssert {
/**
* Creates a new {@link AbstractImageAssert}
to make assertions on actual Image.
* @param actual the Image we want to make assertions on.
*/
protected AbstractImageAssert(A actual, Class selfType) {
super(actual, selfType);
}
/**
* Navigates to the property additionalProperties so that assertions can be done on it
*/
public org.assertj.core.api.MapAssert additionalProperties() {
// check that actual Image we want to make assertions on is not null.
isNotNull();
// return the assertion for the property
return (org.assertj.core.api.MapAssert) assertThat(actual.getAdditionalProperties()).describedAs(com.stakater.kubernetes.assertions.Assertions.joinDescription(this, "additionalProperties"));
}
/**
* Navigates to the property apiVersion so that assertions can be done on it
*/
public org.assertj.core.api.StringAssert apiVersion() {
// check that actual Image we want to make assertions on is not null.
isNotNull();
// return the assertion for the property
return (org.assertj.core.api.StringAssert) assertThat(actual.getApiVersion()).describedAs(com.stakater.kubernetes.assertions.Assertions.joinDescription(this, "apiVersion"));
}
/**
* Navigates to the property dockerImageConfig so that assertions can be done on it
*/
public org.assertj.core.api.StringAssert dockerImageConfig() {
// check that actual Image we want to make assertions on is not null.
isNotNull();
// return the assertion for the property
return (org.assertj.core.api.StringAssert) assertThat(actual.getDockerImageConfig()).describedAs(com.stakater.kubernetes.assertions.Assertions.joinDescription(this, "dockerImageConfig"));
}
/**
* Navigates to the property dockerImageLayers so that assertions can be done on it
*/
public NavigationListAssert dockerImageLayers() {
isNotNull();
// return the assertion for the property
AssertFactory assertFactory = new AssertFactory() {
public ImageLayerAssert createAssert(ImageLayer t) {
return (ImageLayerAssert) assertThat(t);
}
};
NavigationListAssert answer = new NavigationListAssert(actual.getDockerImageLayers(), assertFactory);
answer.describedAs(com.stakater.kubernetes.assertions.Assertions.joinDescription(this, "dockerImageLayers"));
return answer;
}
/**
* Navigates to the property dockerImageManifest so that assertions can be done on it
*/
public org.assertj.core.api.StringAssert dockerImageManifest() {
// check that actual Image we want to make assertions on is not null.
isNotNull();
// return the assertion for the property
return (org.assertj.core.api.StringAssert) assertThat(actual.getDockerImageManifest()).describedAs(com.stakater.kubernetes.assertions.Assertions.joinDescription(this, "dockerImageManifest"));
}
/**
* Navigates to the property dockerImageManifestMediaType so that assertions can be done on it
*/
public org.assertj.core.api.StringAssert dockerImageManifestMediaType() {
// check that actual Image we want to make assertions on is not null.
isNotNull();
// return the assertion for the property
return (org.assertj.core.api.StringAssert) assertThat(actual.getDockerImageManifestMediaType()).describedAs(com.stakater.kubernetes.assertions.Assertions.joinDescription(this, "dockerImageManifestMediaType"));
}
/**
* Navigates to the property dockerImageMetadata so that assertions can be done on it
*/
public io.fabric8.kubernetes.api.model.HasMetadataAssert dockerImageMetadata() {
// check that actual Image we want to make assertions on is not null.
isNotNull();
// return the assertion for the property
return (io.fabric8.kubernetes.api.model.HasMetadataAssert) assertThat(actual.getDockerImageMetadata()).describedAs(com.stakater.kubernetes.assertions.Assertions.joinDescription(this, "dockerImageMetadata"));
}
/**
* Navigates to the property dockerImageMetadataVersion so that assertions can be done on it
*/
public org.assertj.core.api.StringAssert dockerImageMetadataVersion() {
// check that actual Image we want to make assertions on is not null.
isNotNull();
// return the assertion for the property
return (org.assertj.core.api.StringAssert) assertThat(actual.getDockerImageMetadataVersion()).describedAs(com.stakater.kubernetes.assertions.Assertions.joinDescription(this, "dockerImageMetadataVersion"));
}
/**
* Navigates to the property dockerImageReference so that assertions can be done on it
*/
public org.assertj.core.api.StringAssert dockerImageReference() {
// check that actual Image we want to make assertions on is not null.
isNotNull();
// return the assertion for the property
return (org.assertj.core.api.StringAssert) assertThat(actual.getDockerImageReference()).describedAs(com.stakater.kubernetes.assertions.Assertions.joinDescription(this, "dockerImageReference"));
}
/**
* Navigates to the property dockerImageSignatures so that assertions can be done on it
*/
public NavigationListAssert dockerImageSignatures() {
isNotNull();
// return the assertion for the property
AssertFactory assertFactory = new AssertFactory() {
public org.assertj.core.api.StringAssert createAssert(String t) {
return (org.assertj.core.api.StringAssert) assertThat(t);
}
};
NavigationListAssert answer = new NavigationListAssert(actual.getDockerImageSignatures(), assertFactory);
answer.describedAs(com.stakater.kubernetes.assertions.Assertions.joinDescription(this, "dockerImageSignatures"));
return answer;
}
/**
* Navigates to the property kind so that assertions can be done on it
*/
public org.assertj.core.api.StringAssert kind() {
// check that actual Image we want to make assertions on is not null.
isNotNull();
// return the assertion for the property
return (org.assertj.core.api.StringAssert) assertThat(actual.getKind()).describedAs(com.stakater.kubernetes.assertions.Assertions.joinDescription(this, "kind"));
}
/**
* Navigates to the property metadata so that assertions can be done on it
*/
public io.fabric8.kubernetes.api.model.ObjectMetaAssert metadata() {
// check that actual Image we want to make assertions on is not null.
isNotNull();
// return the assertion for the property
return (io.fabric8.kubernetes.api.model.ObjectMetaAssert) assertThat(actual.getMetadata()).describedAs(com.stakater.kubernetes.assertions.Assertions.joinDescription(this, "metadata"));
}
/**
* Navigates to the property signatures so that assertions can be done on it
*/
public NavigationListAssert signatures() {
isNotNull();
// return the assertion for the property
AssertFactory assertFactory = new AssertFactory() {
public ImageSignatureAssert createAssert(ImageSignature t) {
return (ImageSignatureAssert) assertThat(t);
}
};
NavigationListAssert answer = new NavigationListAssert(actual.getSignatures(), assertFactory);
answer.describedAs(com.stakater.kubernetes.assertions.Assertions.joinDescription(this, "signatures"));
return answer;
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy