Skip to content

Commit a0e5039

Browse files
authored
Add package name and fix imports (#605)
Signed-off-by: Sayali Gaikawad <gaiksaya@amazon.com>
1 parent 4165b0c commit a0e5039

File tree

126 files changed

+301
-162
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

126 files changed

+301
-162
lines changed

tests/gradlecheck/CreateMarkDownTableTest.groovy

+3-2
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,10 @@
77
* compatible open source license.
88
*/
99

10-
package gradlecheck
10+
package gradlecheck.tests
1111

12-
import org.junit.*
12+
import gradlecheck.CreateMarkDownTable
13+
import org.junit.Test
1314

1415

1516
class CreateMarkDownTableTest {

tests/gradlecheck/FetchPostMergeFailedTestClassTest.groovy

+4-3
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,12 @@
77
* compatible open source license.
88
*/
99

10-
package gradlecheck
10+
package gradlecheck.tests
1111

12-
import org.junit.*
12+
import gradlecheck.FetchPostMergeFailedTestClass
13+
import org.junit.Before
14+
import org.junit.Test
1315
import groovy.json.JsonOutput
14-
import groovy.mock.interceptor.MockFor
1516

1617
class FetchPostMergeFailedTestClassTest {
1718

tests/gradlecheck/FetchPostMergeFailedTestNameTest.groovy

+4-2
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,11 @@
77
* compatible open source license.
88
*/
99

10-
package gradlecheck
10+
package gradlecheck.tests
1111

12-
import org.junit.*
12+
import gradlecheck.FetchPostMergeFailedTestName
13+
import org.junit.Before
14+
import org.junit.Test
1315
import groovy.json.JsonOutput
1416
import groovy.json.JsonSlurper
1517

tests/gradlecheck/FetchPostMergeTestGitReferenceTest.groovy

+4-3
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,12 @@
77
* compatible open source license.
88
*/
99

10-
package gradlecheck
10+
package gradlecheck.tests
1111

12-
import org.junit.*
12+
import gradlecheck.FetchPostMergeTestGitReference
13+
import org.junit.Before
14+
import org.junit.Test
1315
import groovy.json.JsonOutput
14-
import groovy.json.JsonSlurper
1516

1617
class FetchPostMergeTestGitReferenceTest {
1718

tests/gradlecheck/FetchTestPullRequestsTest.groovy

+4-3
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,12 @@
77
* compatible open source license.
88
*/
99

10-
package gradlecheck
10+
package gradlecheck.tests
1111

12-
import org.junit.*
12+
import gradlecheck.FetchTestPullRequests
13+
import org.junit.Before
14+
import org.junit.Test
1315
import groovy.json.JsonOutput
14-
import groovy.json.JsonSlurper
1516

1617
class FetchTestPullRequestsTest {
1718

tests/gradlecheck/MarkdownComparatorTest.groovy

+4-8
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,11 @@
77
* compatible open source license.
88
*/
99

10-
package gradlecheck;
10+
package gradlecheck.tests
1111

12-
import org.junit.Assert;
13-
import org.junit.Test;
14-
15-
import java.util.ArrayList;
16-
import java.util.HashMap;
17-
import java.util.List;
18-
import java.util.Map;
12+
import gradlecheck.MarkdownComparator
13+
import org.junit.Assert
14+
import org.junit.Test
1915

2016
class MarkdownComparatorTest {
2117

tests/gradlecheck/ParseMarkDownTableTest.groovy

+2-1
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,9 @@
77
* compatible open source license.
88
*/
99

10-
package gradlecheck
10+
package gradlecheck.tests
1111

12+
import gradlecheck.ParseMarkDownTable
1213
import org.junit.Test
1314
import static org.junit.Assert.assertEquals
1415

tests/jenkins/BuildPipelineTest.groovy

+3-2
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,11 @@
99

1010
package jenkins.tests
1111

12-
import org.junit.*
12+
import org.junit.Before
13+
import org.junit.After
1314
import static com.lesfurets.jenkins.unit.global.lib.LibraryConfiguration.library
1415
import static com.lesfurets.jenkins.unit.global.lib.ProjectSource.projectSource
15-
import com.lesfurets.jenkins.unit.*
16+
import com.lesfurets.jenkins.unit.LibClassLoader
1617
import org.yaml.snakeyaml.Yaml
1718

1819
/**

tests/jenkins/LibFunctionTester.groovy

+1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
* this file be licensed under the Apache-2.0 license or a
77
* compatible open source license.
88
*/
9+
package jenkins.tests
910
import jenkins.tests.BuildPipelineTest
1011

1112
abstract class LibFunctionTester extends BuildPipelineTest {

tests/jenkins/TestArchiveAssembleUpload.groovy

+5-3
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,11 @@
99

1010
package jenkins.tests
1111

12-
import org.junit.*
13-
import java.util.*
14-
import java.nio.file.*
12+
import org.junit.Before
13+
import org.junit.Test
14+
import java.nio.file.Files
15+
import java.nio.file.Path
16+
import java.nio.file.StandardCopyOption
1517

1618
class TestArchiveAssembleUpload extends BuildPipelineTest {
1719
@Before

tests/jenkins/TestAssembleManifest.groovy

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*/
99
package jenkins.tests
1010

11-
import org.junit.*
11+
import org.junit.Test
1212

1313
class TestAssembleManifest extends BuildPipelineTest {
1414

tests/jenkins/TestAssembleUpload.groovy

+2-2
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@
99

1010
package jenkins.tests
1111

12-
import org.junit.*
13-
import java.util.*
12+
import org.junit.Before
13+
import org.junit.Test
1414

1515
class TestAssembleUpload extends BuildPipelineTest {
1616
@Before

tests/jenkins/TestBuildArchive.groovy

+2-2
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@
99

1010
package jenkins.tests
1111

12-
import org.junit.*
13-
import java.util.*
12+
import org.junit.Before
13+
import org.junit.Test
1414

1515
class TestBuildArchive extends BuildPipelineTest {
1616
@Before

tests/jenkins/TestBuildAssembleUpload.groovy

+5-3
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,11 @@
99

1010
package jenkins.tests
1111

12-
import org.junit.*
13-
import java.util.*
14-
import java.nio.file.*
12+
import org.junit.Before
13+
import org.junit.Test
14+
import java.nio.file.Files
15+
import java.nio.file.Path
16+
import java.nio.file.StandardCopyOption
1517

1618
class TestBuildAssembleUpload extends BuildPipelineTest {
1719
@Before

tests/jenkins/TestBuildDockerImage.groovy

+2-2
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@
99

1010
package jenkins.tests
1111

12-
import org.junit.*
13-
import java.util.*
12+
import org.junit.Before
13+
import org.junit.Test
1414

1515
class TestBuildDockerImage extends BuildPipelineTest {
1616
@Override

tests/jenkins/TestBuildInfoYaml.groovy

+1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
* this file be licensed under the Apache-2.0 license or a
77
* compatible open source license.
88
*/
9+
package jenkins.tests
910

1011
import jenkins.tests.BuildPipelineTest
1112
import org.junit.Before

tests/jenkins/TestBuildManifest.groovy

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
package jenkins.tests
1111

12-
import org.junit.*
12+
import org.junit.Test
1313

1414
class TestBuildManifest extends BuildPipelineTest {
1515
@Test

tests/jenkins/TestBuildMessage.groovy

+3-1
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,10 @@
88
*/
99

1010
package jenkins.tests
11+
1112
import jenkins.tests.BuildPipelineTest
12-
import org.junit.*
13+
import org.junit.Before
14+
import org.junit.Test
1315

1416
class TestBuildMessage extends BuildPipelineTest {
1517

tests/jenkins/TestBuildUploadManifestSHA.groovy

+2-2
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@
99

1010
package jenkins.tests
1111

12-
import org.junit.*
13-
import java.util.*
12+
import org.junit.Before
13+
import org.junit.Test
1414

1515
class TestBuildUploadManifestSHA extends BuildPipelineTest {
1616
@Override

tests/jenkins/TestBuildYumRepo.groovy

+2-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@
88
*/
99
package jenkins.tests
1010

11-
import org.junit.*
11+
import org.junit.Before
12+
import org.junit.Test
1213

1314
class TestBuildYumRepo extends BuildPipelineTest {
1415

tests/jenkins/TestComponentBuildStatus.groovy

+5-4
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,12 @@
77
* compatible open source license.
88
*/
99

10-
package jenkins
10+
package jenkins.tests
1111

12-
import org.junit.*
12+
import jenkins.ComponentBuildStatus
13+
import org.junit.Before
14+
import org.junit.Test
1315
import groovy.json.JsonOutput
14-
import groovy.mock.interceptor.MockFor
1516

1617
class TestComponentBuildStatus {
1718

@@ -73,7 +74,7 @@ class TestComponentBuildStatus {
7374
def expectedOutput = JsonOutput.toJson([
7475
_source: [
7576
"component",
76-
],
77+
],
7778
query: [
7879
bool: [
7980
filter: [

tests/jenkins/TestComponentIntegTestStatus.groovy

+5-3
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,11 @@
77
* compatible open source license.
88
*/
99

10-
package jenkins
10+
package jenkins.tests
1111

12-
import org.junit.*
12+
import jenkins.ComponentIntegTestStatus
13+
import org.junit.Before
14+
import org.junit.Test
1315
import groovy.json.JsonOutput
1416
import groovy.json.JsonSlurper
1517

@@ -104,7 +106,7 @@ class TestComponentIntegTestStatus {
104106
size: 50,
105107
_source: [
106108
"component",
107-
],
109+
],
108110
query: [
109111
bool: [
110112
filter: [

tests/jenkins/TestComponentRepoData.groovy

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
* compatible open source license.
88
*/
99

10-
package jenkins
10+
package jenkins.tests
1111

1212
import org.junit.*
1313
import groovy.json.JsonOutput

tests/jenkins/TestCopyContainer.groovy

+2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@
66
* this file be licensed under the Apache-2.0 license or a
77
* compatible open source license.
88
*/
9+
package jenkins.tests
10+
911
import jenkins.tests.BuildPipelineTest
1012
import org.junit.*
1113
import static org.hamcrest.CoreMatchers.equalTo

tests/jenkins/TestCreateGithubIssue.groovy

+1-2
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ import org.junit.Test
1515
import static com.lesfurets.jenkins.unit.MethodCall.callArgsToString
1616
import static org.hamcrest.CoreMatchers.hasItem
1717
import static org.hamcrest.MatcherAssert.assertThat
18-
import com.lesfurets.jenkins.unit.*
1918

2019

2120
class TestCreateGithubIssue extends BuildPipelineTest {
@@ -47,7 +46,7 @@ class TestCreateGithubIssue extends BuildPipelineTest {
4746
assertThat(getCommands('println', ''), hasItem("Issue already exists, adding a comment"))
4847
assertThat(getCommands('sh', 'script'), hasItem("""{script=gh issue comment bbb\nccc --repo https://github.com/opensearch-project/opensearch-build --body \"Test GH issue body\", returnStdout=true}"""))
4948
}
50-
49+
5150
@Test
5251
void testCreateGithubIssueCreate() {
5352
this.registerLibTester(new CreateGithubIssueLibTester(

tests/jenkins/TestCreateIntegTestMarkDownTable.groovy

+10-10
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
package jenkins
1111

12-
import org.junit.*
12+
import org.junit.Test
1313

1414
class TestCreateIntegTestMarkDownTable {
1515

@@ -19,20 +19,20 @@ class TestCreateIntegTestMarkDownTable {
1919
def releaseOwners = ['foo', 'bar']
2020
def tableData = [
2121
[
22-
architecture:"x64",
23-
distribution:"tar",
24-
integ_test_build_url:"some_integ_test_url",
25-
platform:"linux",
22+
architecture:"x64",
23+
distribution:"tar",
24+
integ_test_build_url:"some_integ_test_url",
25+
platform:"linux",
2626
test_report_manifest_yml:"test_report_dummy_url",
2727
distribution_build_number: '1234',
2828
rc_number: 1,
2929
metrics_visualization_url: "some_url"
30-
],
30+
],
3131
[
32-
architecture:"arm64",
33-
distribution:"tar",
34-
integ_test_build_url:"integ_test_dummy_url",
35-
platform:"linux",
32+
architecture:"arm64",
33+
distribution:"tar",
34+
integ_test_build_url:"integ_test_dummy_url",
35+
platform:"linux",
3636
test_report_manifest_yml:"test_report_2_dummy_url",
3737
distribution_build_number: '1234',
3838
rc_number: 1,

tests/jenkins/TestCreateReleaseTag.groovy

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
* this file be licensed under the Apache-2.0 license or a
77
* compatible open source license.
88
*/
9-
9+
package jenkins.tests
1010

1111
import jenkins.tests.BuildPipelineTest
1212
import org.junit.Before

tests/jenkins/TestCreateTestResultsMessage.groovy

+1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
* this file be licensed under the Apache-2.0 license or a
77
* compatible open source license.
88
*/
9+
package jenkins.tests
910

1011
import jenkins.tests.BuildPipelineTest
1112
import org.junit.Before

tests/jenkins/TestDetectDockerImage.groovy

+1-2
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,7 @@
99

1010
package jenkins.tests
1111

12-
import org.junit.*
13-
import java.util.*
12+
import org.junit.Test
1413

1514
class TestDetectDockerImage extends BuildPipelineTest {
1615
@Test

0 commit comments

Comments
 (0)