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

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

      
    
Rootfs path

      
    
Size
3974 (3.9 KB)
MD5
6eadfc9c5c62d90b41bf0e9d2fcaf323
SHA1
06ca647062c378deef0634c7597ebce2b8e15ca6
SHA256
439945f56ad48da53e3ffedf5bf4e71062dbc734edbabf02f4332e096d88ecdb
SHA512

      
    
SHA1_git
cb4bbf0073208e63b2b48ca7045faf6417636b52
Is binary

      
    
Is text
True
Is archive

      
    
Is media

      
    
Is legal

      
    
Is manifest

      
    
Is readme

      
    
Is top level

      
    
Is key file

      
    
TestHostConfigAutomaticDeploymentDeleteC.java | 3.9 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 TestHostConfigAutomaticDeploymentDeleteC 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 Y N N WAR N N - - * Y Y N N XML N N - - * Y Y N Y DIR R Y - R 1,2 * Y Y N Y WAR N N - - * Y Y N Y XML R Y - Y * * 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 testDeleteXmlWarRemoveWar() throws Exception { doTestDelete(true, false, false, true, false, WAR, false, false, false, null); } @Test public void testDeleteXmlWarRemoveXml() throws Exception { doTestDelete(true, false, false, true, false, XML, false, true, false, WAR_COOKIE_NAME); } @Test public void testDeleteXmlWarRemoveXmlCopyXml() throws Exception { ((StandardHost) getTomcatInstance().getHost()).setCopyXML(true); doTestDelete(true, false, false, true, false, XML, true, true, false, WAR_COOKIE_NAME); } @Test public void testDeleteXmlWarDirRemoveDir() throws Exception { doTestDelete(true, false, false, true, true, DIR, false, true, true, WAR_COOKIE_NAME); } @Test public void testDeleteXmlWarDirRemoveDirCopyXml() throws Exception { ((StandardHost) getTomcatInstance().getHost()).setCopyXML(true); doTestDelete(true, false, false, true, true, DIR, true, true, true, WAR_COOKIE_NAME); } @Test public void testDeleteXmlWarDirRemoveWar() throws Exception { doTestDelete(true, false, false, true, true, WAR, false, false, false, null); } @Test public void testDeleteXmlWarDirRemoveWarCopyXml() throws Exception { ((StandardHost) getTomcatInstance().getHost()).setCopyXML(true); doTestDelete(true, false, false, true, true, WAR, false, false, false, null); } @Test public void testDeleteXmlWarDirRemoveXml() throws Exception { doTestDelete(true, false, false, true, true, XML, false, true, true, DIR_COOKIE_NAME); } @Test public void testDeleteXmlWarDirRemoveXmlCopyXml() throws Exception { ((StandardHost) getTomcatInstance().getHost()).setCopyXML(true); doTestDelete(true, false, false, true, true, XML, true, true, true, WAR_COOKIE_NAME); } }
Detected license expression
apache-2.0
Detected license expression (SPDX)
Apache-2.0
Percentage of license text
27.8
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