ttomcat-1778514358873.zip-extract/apache-tomcat-11.0.18-src/test/org/apache/catalina/startup/TestHostConfigAutomaticDeploymentDeleteB.java

Path
ttomcat-1778514358873.zip-extract/apache-tomcat-11.0.18-src/test/org/apache/catalina/startup/TestHostConfigAutomaticDeploymentDeleteB.java
Status
scanned
Type
file
Name
TestHostConfigAutomaticDeploymentDeleteB.java
Extension
.java
Programming language
Java
Mime type
text/plain
File type
ASCII text, with CRLF line terminators
Tag

      
    
Rootfs path

      
    
Size
4313 (4.2 KB)
MD5
f2f30d37a8b28fbb5c132f07a8c7713c
SHA1
eb19630fa56372a257870bf882192c20c3cdebd8
SHA256
e049b50987462a2cba7b444014882b2ade8531f29cb3814b311243ec174b4564
SHA512

      
    
SHA1_git
ccbeebf4fba82d499ec0928bb24a20b067369447
Is binary

      
    
Is text
True
Is archive

      
    
Is media

      
    
Is legal

      
    
Is manifest

      
    
Is readme

      
    
Is top level

      
    
Is key file

      
    
TestHostConfigAutomaticDeploymentDeleteB.java | 4.2 KB |

/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may not use this file except in compliance with * the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.catalina.startup; import org.junit.Test; import org.apache.catalina.core.StandardHost; /** * The purpose of this class is to test the automatic deployment features of the * {@link HostConfig} implementation. */ public class TestHostConfigAutomaticDeploymentDeleteB extends HostConfigAutomaticDeploymentBaseTest { /* * Expected behaviour for the deletion of files. * * Artifacts present Artifact Artifacts remaining * XML WAR EXT DIR Removed XML WAR EXT DIR Notes * Y N N N XML N - - - * Y N N Y DIR N - - N * Y N N Y XML R - - Y 2 * Y N Y N EXT Y - N - * Y N Y N XML N - Y - * Y N Y Y DIR R - Y R 1,2 * Y N Y Y EXT Y - N N * Y N Y Y XML N - Y N * * Notes: 1. The DIR will be re-created since unpackWARs is true. * 2. The XML will be extracted from the WAR/DIR if deployXML and * copyXML are true. */ @Test public void testDeleteXmlRemoveXml() throws Exception { doTestDelete(true, false, false, false, false, XML, false, false, false, null); } @Test public void testDeleteXmlDirRemoveDir() throws Exception { doTestDelete(true, false, false, false, true, DIR, false, false, false, null); } @Test public void testDeleteXmlDirRemoveXml() throws Exception { doTestDelete(true, false, false, false, true, XML, false, false, true, DIR_COOKIE_NAME); } @Test public void testDeleteXmlDirRemoveXmlCopyXml() throws Exception { ((StandardHost) getTomcatInstance().getHost()).setCopyXML(true); doTestDelete(true, false, false, false, true, XML, true, false, true, DIR_COOKIE_NAME); } @Test public void testDeleteXmlExtwarRemoveExt() throws Exception { doTestDelete(true, true, false, false, false, EXT, true, false, false, XML_COOKIE_NAME); } @Test public void testDeleteXmlExtdirRemoveExt() throws Exception { doTestDelete(true, false, true, false, false, EXT, true, false, false, XML_COOKIE_NAME); } @Test public void testDeleteXmlExtwarRemoveXml() throws Exception { doTestDelete(true, true, false, false, false, XML, false, false, false, null); } @Test public void testDeleteXmlExtdirRemoveXml() throws Exception { doTestDelete(true, false, true, false, false, XML, false, false, false, null); } @Test public void testDeleteXmlExtwarDirRemoveDir() throws Exception { doTestDelete(true, true, false, false, true, DIR, true, false, true, XML_COOKIE_NAME); } @Test public void testDeleteXmlExtwarDirRemoveExt() throws Exception { doTestDelete(true, true, false, false, true, EXT, true, false, false, XML_COOKIE_NAME); } @Test public void testDeleteXmlExtwarDirRemoveXml() throws Exception { doTestDelete(true, true, false, false, true, XML, false, false, false, null); } }
Detected license expression
apache-2.0
Detected license expression (SPDX)
Apache-2.0
Percentage of license text
25.37
Copyrights

      
    
Holders

      
    
Authors

      
    
License detections License expression License expression SPDX
apache_2_0-4bde3f57-78aa-4201-96bf-531cba09e7de apache-2.0 Apache-2.0
URL Start line End line
http://www.apache.org/licenses/LICENSE-2.0 9 9