/** * @throws SrampException */ private BaseArtifactType createDocument(int idx) throws SrampException { String artifactFileName = "s-ramp-press-release.pdf"; //$NON-NLS-1$ InputStream content = this.getClass().getResourceAsStream("/sample-files/core/" + artifactFileName); //$NON-NLS-1$ Document document = new Document(); document.setName(artifactFileName + "-" + idx); //$NON-NLS-1$ document.setVersion("1.0.3"); //$NON-NLS-1$ document.setArtifactType(BaseArtifactEnum.DOCUMENT); BaseArtifactType artifact1 = persistenceManager.persistArtifact(document, content); Assert.assertNotNull(artifact1); return artifact1; }