Skip to content

Commit 88f18b9

Browse files
committed
test:为代理模块的测试类添加 Apache License 2.0 开源许可证
- 在 FileCertChangeSourceTest、GrpcServerTest、GrpcSslContextTest、 MultiProtocolTlsHelperTest 和 TlsCertificateManagerTest 五个测试类中 添加了 Apache License 2.0 开源许可证的版权信息 - 删除了 GrpcSslContextTest 中的重复代码 Signed-off-by: Async <raisinata@foxmail.com>
1 parent ac1c1d6 commit 88f18b9

5 files changed

Lines changed: 80 additions & 3 deletions

File tree

proxy/src/test/java/org/apache/rocketmq/proxy/grpc/GrpcServerTest.java

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,19 @@
1+
/*
2+
* Licensed to the Apache Software Foundation (ASF) under one or more
3+
* contributor license agreements. See the NOTICE file distributed with
4+
* this work for additional information regarding copyright ownership.
5+
* The ASF licenses this file to You under the Apache License, Version 2.0
6+
* (the "License"); you may not use this file except in compliance with
7+
* the License. You may obtain a copy of the License at
8+
*
9+
* http://www.apache.org/licenses/LICENSE-2.0
10+
*
11+
* Unless required by applicable law or agreed to in writing, software
12+
* distributed under the License is distributed on an "AS IS" BASIS,
13+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
* See the License for the specific language governing permissions and
15+
* limitations under the License.
16+
*/
117
package org.apache.rocketmq.proxy.grpc;
218

319
import io.grpc.Server;

proxy/src/test/java/org/apache/rocketmq/proxy/grpc/GrpcSslContextTest.java

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,22 @@
1+
/*
2+
* Licensed to the Apache Software Foundation (ASF) under one or more
3+
* contributor license agreements. See the NOTICE file distributed with
4+
* this work for additional information regarding copyright ownership.
5+
* The ASF licenses this file to You under the Apache License, Version 2.0
6+
* (the "License"); you may not use this file except in compliance with
7+
* the License. You may obtain a copy of the License at
8+
*
9+
* http://www.apache.org/licenses/LICENSE-2.0
10+
*
11+
* Unless required by applicable law or agreed to in writing, software
12+
* distributed under the License is distributed on an "AS IS" BASIS,
13+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
* See the License for the specific language governing permissions and
15+
* limitations under the License.
16+
*/
117
package org.apache.rocketmq.proxy.grpc;
218

319
import io.grpc.netty.shaded.io.grpc.netty.GrpcHttp2ConnectionHandler;
4-
import io.grpc.netty.shaded.io.netty.channel.ChannelHandler;
520
import io.grpc.netty.shaded.io.netty.channel.ChannelHandlerContext;
621
import io.grpc.netty.shaded.io.netty.channel.ChannelPipeline;
722
import io.grpc.netty.shaded.io.netty.handler.ssl.SslContext;
@@ -29,8 +44,6 @@
2944
import org.powermock.reflect.Whitebox;
3045

3146
import static org.assertj.core.api.Assertions.assertThat;
32-
import static org.mockito.ArgumentMatchers.any;
33-
import static org.mockito.ArgumentMatchers.anyString;
3447
import static org.mockito.Mockito.when;
3548

3649
@RunWith(MockitoJUnitRunner.class)

proxy/src/test/java/org/apache/rocketmq/proxy/remoting/MultiProtocolTlsHelperTest.java

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,19 @@
1+
/*
2+
* Licensed to the Apache Software Foundation (ASF) under one or more
3+
* contributor license agreements. See the NOTICE file distributed with
4+
* this work for additional information regarding copyright ownership.
5+
* The ASF licenses this file to You under the Apache License, Version 2.0
6+
* (the "License"); you may not use this file except in compliance with
7+
* the License. You may obtain a copy of the License at
8+
*
9+
* http://www.apache.org/licenses/LICENSE-2.0
10+
*
11+
* Unless required by applicable law or agreed to in writing, software
12+
* distributed under the License is distributed on an "AS IS" BASIS,
13+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
* See the License for the specific language governing permissions and
15+
* limitations under the License.
16+
*/
117
package org.apache.rocketmq.proxy.remoting;
218

319
import io.netty.handler.ssl.OpenSsl;

proxy/src/test/java/org/apache/rocketmq/proxy/service/cert/FileCertChangeSourceTest.java

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,19 @@
1+
/*
2+
* Licensed to the Apache Software Foundation (ASF) under one or more
3+
* contributor license agreements. See the NOTICE file distributed with
4+
* this work for additional information regarding copyright ownership.
5+
* The ASF licenses this file to You under the Apache License, Version 2.0
6+
* (the "License"); you may not use this file except in compliance with
7+
* the License. You may obtain a copy of the License at
8+
*
9+
* http://www.apache.org/licenses/LICENSE-2.0
10+
*
11+
* Unless required by applicable law or agreed to in writing, software
12+
* distributed under the License is distributed on an "AS IS" BASIS,
13+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
* See the License for the specific language governing permissions and
15+
* limitations under the License.
16+
*/
117
package org.apache.rocketmq.proxy.service.cert;
218

319
import java.io.File;

proxy/src/test/java/org/apache/rocketmq/proxy/service/cert/TlsCertificateManagerTest.java

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,19 @@
1+
/*
2+
* Licensed to the Apache Software Foundation (ASF) under one or more
3+
* contributor license agreements. See the NOTICE file distributed with
4+
* this work for additional information regarding copyright ownership.
5+
* The ASF licenses this file to You under the Apache License, Version 2.0
6+
* (the "License"); you may not use this file except in compliance with
7+
* the License. You may obtain a copy of the License at
8+
*
9+
* http://www.apache.org/licenses/LICENSE-2.0
10+
*
11+
* Unless required by applicable law or agreed to in writing, software
12+
* distributed under the License is distributed on an "AS IS" BASIS,
13+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
* See the License for the specific language governing permissions and
15+
* limitations under the License.
16+
*/
117
package org.apache.rocketmq.proxy.service.cert;
218

319
import java.io.InputStream;

0 commit comments

Comments
 (0)