forked from kubernetes/kubernetes
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test: setup embedded file sources for manifests
Signed-off-by: Nabarun Pal <[email protected]>
- Loading branch information
1 parent
3af6329
commit 68b334d
Showing
6 changed files
with
153 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
/* | ||
Copyright 2021 The Kubernetes Authors. | ||
Licensed 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 testdata | ||
|
||
import ( | ||
"embed" | ||
|
||
"k8s.io/kubernetes/test/e2e/framework/testfiles" | ||
) | ||
|
||
//go:embed conformance.yaml ineligible_endpoints.yaml | ||
var conformanceTestdataFS embed.FS | ||
|
||
func GetConformanceTestdataFS() testfiles.EmbeddedFileSource { | ||
return testfiles.EmbeddedFileSource{ | ||
EmbeddedFS: conformanceTestdataFS, | ||
Root: "test/conformance/testdata", | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
/* | ||
Copyright 2021 The Kubernetes Authors. | ||
Licensed 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 testing_manifests | ||
|
||
import ( | ||
"embed" | ||
|
||
e2etestfiles "k8s.io/kubernetes/test/e2e/framework/testfiles" | ||
) | ||
|
||
//go:embed flexvolume guestbook kubectl sample-device-plugin.yaml scheduling/nvidia-driver-installer.yaml statefulset storage-csi | ||
var e2eTestingManifestsFS embed.FS | ||
|
||
func GetE2ETestingManifestsFS() e2etestfiles.EmbeddedFileSource { | ||
return e2etestfiles.EmbeddedFileSource{ | ||
EmbeddedFS: e2eTestingManifestsFS, | ||
Root: "test/e2e/testing-manifests", | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
/* | ||
Copyright 2021 The Kubernetes Authors. | ||
Licensed 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 testing_manifests | ||
|
||
import ( | ||
"embed" | ||
|
||
e2etestfiles "k8s.io/kubernetes/test/e2e/framework/testfiles" | ||
) | ||
|
||
//go:embed *.yaml | ||
var e2eNodeTestingManifestsFS embed.FS | ||
|
||
func GetE2ENodeTestingManifestsFS() e2etestfiles.EmbeddedFileSource { | ||
return e2etestfiles.EmbeddedFileSource{ | ||
EmbeddedFS: e2eNodeTestingManifestsFS, | ||
Root: "test/e2e_node/testing-manifests", | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
/* | ||
Copyright 2021 The Kubernetes Authors. | ||
Licensed 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 fixtures | ||
|
||
import ( | ||
"embed" | ||
|
||
"k8s.io/kubernetes/test/e2e/framework/testfiles" | ||
) | ||
|
||
//go:embed doc-yaml/user-guide/liveness doc-yaml/user-guide/secrets doc-yaml/user-guide/downward-api doc-yaml/user-guide/update-demo | ||
var testFixturesFS embed.FS | ||
|
||
func GetTestFixturesFS() testfiles.EmbeddedFileSource { | ||
return testfiles.EmbeddedFileSource{ | ||
EmbeddedFS: testFixturesFS, | ||
Root: "test/fixtures", | ||
} | ||
} |