|
| 1 | +/* |
| 2 | + This file is part of the iText (R) project. |
| 3 | + Copyright (c) 1998-2020 iText Group NV |
| 4 | + Authors: iText Software. |
| 5 | +
|
| 6 | + This program is offered under a commercial and under the AGPL license. |
| 7 | + For commercial licensing, contact us at https://itextpdf.com/sales. For AGPL licensing, see below. |
| 8 | +
|
| 9 | + AGPL licensing: |
| 10 | + This program is free software: you can redistribute it and/or modify |
| 11 | + it under the terms of the GNU Affero General Public License as published by |
| 12 | + the Free Software Foundation, either version 3 of the License, or |
| 13 | + (at your option) any later version. |
| 14 | +
|
| 15 | + This program is distributed in the hope that it will be useful, |
| 16 | + but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 17 | + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 18 | + GNU Affero General Public License for more details. |
| 19 | +
|
| 20 | + You should have received a copy of the GNU Affero General Public License |
| 21 | + along with this program. If not, see <https://www.gnu.org/licenses/>. |
| 22 | + */ |
| 23 | +package com.itextpdf.html2pdf.css; |
| 24 | + |
| 25 | +import com.itextpdf.html2pdf.ExtendedHtmlConversionITextTest; |
| 26 | +import com.itextpdf.test.annotations.type.IntegrationTest; |
| 27 | + |
| 28 | +import java.io.IOException; |
| 29 | +import org.junit.BeforeClass; |
| 30 | +import org.junit.Test; |
| 31 | +import org.junit.experimental.categories.Category; |
| 32 | + |
| 33 | +@Category(IntegrationTest.class) |
| 34 | +public class BackgroundRepeatTest extends ExtendedHtmlConversionITextTest { |
| 35 | + |
| 36 | + public static final String SOURCE_FOLDER = "./src/test/resources/com/itextpdf/html2pdf/css/BackgroundRepeatTest/"; |
| 37 | + public static final String DESTINATION_FOLDER = "./target/test/com/itextpdf/html2pdf/css/BackgroundRepeatTest/"; |
| 38 | + |
| 39 | + @BeforeClass |
| 40 | + public static void beforeClass() { |
| 41 | + createDestinationFolder(DESTINATION_FOLDER); |
| 42 | + } |
| 43 | + |
| 44 | + @Test |
| 45 | + //TODO: DEVSIX-4370 update cmp file |
| 46 | + public void imageBckgRepeatTest() throws IOException, InterruptedException { |
| 47 | + convertToPdfAndCompare("imageBckgRepeat", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 48 | + } |
| 49 | + |
| 50 | + @Test |
| 51 | + //TODO: DEVSIX-4370 update cmp file |
| 52 | + public void imageBckgNoRepeatTest() throws InterruptedException, IOException { |
| 53 | + convertToPdfAndCompare("imageBckgNoRepeat", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 54 | + } |
| 55 | + |
| 56 | + @Test |
| 57 | + //TODO: DEVSIX-4370 update cmp file |
| 58 | + public void imageBckgRoundTest() throws InterruptedException, IOException { |
| 59 | + convertToPdfAndCompare("imageBckgRound", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 60 | + } |
| 61 | + |
| 62 | + @Test |
| 63 | + //TODO: DEVSIX-4370 update cmp file |
| 64 | + public void imageBckgSpaceTest() throws InterruptedException, IOException { |
| 65 | + convertToPdfAndCompare("imageBckgSpace", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 66 | + } |
| 67 | + |
| 68 | + @Test |
| 69 | + //TODO: DEVSIX-4370 update cmp file |
| 70 | + public void imageBckgRepeatXTest() throws InterruptedException, IOException { |
| 71 | + convertToPdfAndCompare("imageBckgRepeatX", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 72 | + } |
| 73 | + |
| 74 | + @Test |
| 75 | + //TODO: DEVSIX-4370 update cmp file |
| 76 | + public void imageBckgRepeatYTest() throws InterruptedException, IOException { |
| 77 | + convertToPdfAndCompare("imageBckgRepeatY", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 78 | + } |
| 79 | + |
| 80 | + @Test |
| 81 | + //TODO: DEVSIX-4370 update cmp file |
| 82 | + public void linearGradientBckgRepeatTest() throws InterruptedException, IOException { |
| 83 | + convertToPdfAndCompare("linearGradientBckgRepeat", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 84 | + } |
| 85 | + |
| 86 | + @Test |
| 87 | + //TODO: DEVSIX-4370 update cmp file |
| 88 | + public void linearGradientBckgNoRepeatTest() throws InterruptedException, IOException { |
| 89 | + convertToPdfAndCompare("linearGradientBckgNoRepeat", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 90 | + } |
| 91 | + |
| 92 | + @Test |
| 93 | + //TODO: DEVSIX-4370 update cmp file |
| 94 | + public void linearGradientBckgRoundTest() throws IOException, InterruptedException { |
| 95 | + convertToPdfAndCompare("linearGradientBckgRound", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 96 | + } |
| 97 | + |
| 98 | + @Test |
| 99 | + //TODO: DEVSIX-1708 update cmp file |
| 100 | + public void linearGradientBckgSpaceTest() throws IOException, InterruptedException { |
| 101 | + convertToPdfAndCompare("linearGradientBckgSpace", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 102 | + } |
| 103 | + |
| 104 | + @Test |
| 105 | + //TODO: DEVSIX-4370 update cmp file |
| 106 | + public void linearGradientBckgRepeatXTest() throws IOException, InterruptedException { |
| 107 | + convertToPdfAndCompare("linearGradientBckgRepeatX", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 108 | + } |
| 109 | + |
| 110 | + @Test |
| 111 | + //TODO: DEVSIX-4370 update cmp file |
| 112 | + public void linearGradientBckgRepeatYTest() throws IOException, InterruptedException { |
| 113 | + convertToPdfAndCompare("linearGradientBckgRepeatY", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 114 | + } |
| 115 | + |
| 116 | + @Test |
| 117 | + //TODO: DEVSIX-4370 update cmp file |
| 118 | + public void imageBckgRepeatAndSpaceTest() throws IOException, InterruptedException { |
| 119 | + convertToPdfAndCompare("imageBckgRepeatAndSpace", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 120 | + } |
| 121 | + |
| 122 | + @Test |
| 123 | + //TODO: DEVSIX-4370 update cmp file |
| 124 | + public void imageBckgRoundAndSpaceTest() throws IOException, InterruptedException { |
| 125 | + convertToPdfAndCompare("imageBckgRoundAndSpace", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 126 | + } |
| 127 | + |
| 128 | + @Test |
| 129 | + //TODO: DEVSIX-4370 update cmp file |
| 130 | + public void bckgRepeatAndBckgPositionXTest() throws IOException, InterruptedException { |
| 131 | + convertToPdfAndCompare("bckgRepeatAndBckgPositionX", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 132 | + } |
| 133 | + |
| 134 | + @Test |
| 135 | + //TODO: DEVSIX-4370 update cmp file |
| 136 | + public void bckgRepeatAndBckgPositionYTest() throws IOException, InterruptedException { |
| 137 | + convertToPdfAndCompare("bckgRepeatAndBckgPositionY", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 138 | + } |
| 139 | + |
| 140 | + @Test |
| 141 | + //TODO: DEVSIX-4370 update cmp file |
| 142 | + public void bckgRoundSpaceAndBckgPositionXTest() throws IOException, InterruptedException { |
| 143 | + convertToPdfAndCompare("bckgRoundSpaceAndBckgPositionX", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 144 | + } |
| 145 | + |
| 146 | + @Test |
| 147 | + //TODO: DEVSIX-4370 update cmp file |
| 148 | + public void bckgSpaceRoundAndBckgPositionYTest() throws IOException, InterruptedException { |
| 149 | + convertToPdfAndCompare("bckgSpaceRoundAndBckgPositionY", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 150 | + } |
| 151 | + |
| 152 | + @Test |
| 153 | + //TODO: DEVSIX-4370 update cmp file |
| 154 | + public void bckgRepeatXAndBckgPositionYTest() throws IOException, InterruptedException { |
| 155 | + convertToPdfAndCompare("bckgRepeatXAndBckgPositionY", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 156 | + } |
| 157 | + |
| 158 | + @Test |
| 159 | + //TODO: DEVSIX-4370 update cmp file |
| 160 | + public void bckgRepeatYAndBckgPositionXTest() throws IOException, InterruptedException { |
| 161 | + convertToPdfAndCompare("bckgRepeatYAndBckgPositionX", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 162 | + } |
| 163 | + |
| 164 | + @Test |
| 165 | + //TODO: DEVSIX-4370 update cmp file |
| 166 | + public void bckgRoundAndBckgPositionTest() throws IOException, InterruptedException { |
| 167 | + convertToPdfAndCompare("bckgRoundAndBckgPosition", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 168 | + } |
| 169 | + |
| 170 | + @Test |
| 171 | + //TODO: DEVSIX-4370 update cmp file |
| 172 | + public void bckgRoundAndNegativeBckgPositionTest() throws IOException, InterruptedException { |
| 173 | + convertToPdfAndCompare("bckgRoundAndNegativeBckgPosition", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 174 | + } |
| 175 | + |
| 176 | + @Test |
| 177 | + //TODO: DEVSIX-4370 update cmp file |
| 178 | + public void bckgSpaceAndBckgPositionTest() throws IOException, InterruptedException { |
| 179 | + convertToPdfAndCompare("bckgSpaceAndBckgPosition", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 180 | + } |
| 181 | + |
| 182 | + @Test |
| 183 | + //TODO: DEVSIX-4370 update cmp file |
| 184 | + public void bckgSpaceAndBckgPositionPageSeparationTest() throws IOException, InterruptedException { |
| 185 | + convertToPdfAndCompare("bckgSpaceAndBckgPositionPageSeparation", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 186 | + } |
| 187 | + |
| 188 | + @Test |
| 189 | + //TODO: DEVSIX-4370 update cmp file |
| 190 | + public void bckgSpaceAndNegativeBckgPositionTest() throws IOException, InterruptedException { |
| 191 | + convertToPdfAndCompare("bckgSpaceAndNegativeBckgPosition", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 192 | + } |
| 193 | + |
| 194 | + @Test |
| 195 | + //TODO: DEVSIX-4370 update cmp file |
| 196 | + public void bckgRoundRemainsLessHalfOfImageTest() throws IOException, InterruptedException { |
| 197 | + convertToPdfAndCompare("bckgRoundRemainsLessHalfOfImage", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 198 | + } |
| 199 | + |
| 200 | + @Test |
| 201 | + //TODO: DEVSIX-4370 update cmp file |
| 202 | + public void bckgRoundRemainsMoreHalfOfImageTest() throws IOException, InterruptedException { |
| 203 | + convertToPdfAndCompare("bckgRoundRemainsMoreHalfOfImage", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 204 | + } |
| 205 | + |
| 206 | + @Test |
| 207 | + //TODO: DEVSIX-4370 update cmp file |
| 208 | + public void bckgRoundCompressAndStretchImageTest() throws IOException, InterruptedException { |
| 209 | + convertToPdfAndCompare("bckgRoundCompressAndStretchImage", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 210 | + } |
| 211 | + |
| 212 | + @Test |
| 213 | + //TODO: DEVSIX-4370 update cmp file |
| 214 | + public void imageBckgRoundBckgSizeLessThanImageTest() throws IOException, InterruptedException { |
| 215 | + convertToPdfAndCompare("imageBckgRoundBckgSizeLessThanImage", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 216 | + } |
| 217 | + |
| 218 | + @Test |
| 219 | + //TODO: DEVSIX-4370 update cmp file |
| 220 | + public void imageBckgSpaceBckgSizeLessThanImageTest() throws IOException, InterruptedException { |
| 221 | + convertToPdfAndCompare("imageBckgSpaceBckgSizeLessThanImage", SOURCE_FOLDER, DESTINATION_FOLDER); |
| 222 | + } |
| 223 | +} |
0 commit comments