Commit graph

34 commits

Author SHA1 Message Date
Patrick Ohly
62cfe57459 e2e_node: avoid polluting e2e_node command line with helper packages
e2e_node.test depends on test/e2e_node/builder and test/e2e_node/remote because
test/e2e_node/services/ uses some small helper functions from those two
packages. But e2e_node.test itself never builds any Go binaries, nor does it
run remote testing - that functionality is provided by the separate
test/e2e_node/runner commands.

Therefore these two packages should not put their command line flags into
flag.CommandLine because then they show up in the command line of e2e_node test
unnecessarily.

This change removes the following flags from the e2e_node.test command line:

    diff -r before/e2e_node after/e2e_node
    7,8d6
    <       --build-only                                                 If true, build e2e_node_test.tar.gz and exit.
    <       --cleanup                                                    If true remove files from remote hosts and delete temporary instances (default true)
    20d17
    <       --delete-instances                                           If true, delete any instances created (default true)
    42d38
    <       --ginkgo-flags string                                        Passed to ginkgo to specify additional flags such as --skip=.
    95d90
    <       --gubernator                                                 If true, output Gubernator link to view logs
    97d91
    <       --hosts string                                               hosts to test
    99,100d92
    <       --image-config-dir string                                    (optional) path to image config files
    <       --image-config-file string                                   yaml file describing images to run
    103d94
    <       --images string                                              images to test
    105,106d95
    <       --instance-name-prefix string                                prefix for instance names
    <       --k8s-bin-dir string                                         Directory containing k8s kubelet binaries.
    120d108
    <       --mode string                                                Mode to operate in. One of gce|ssh. Defaults to gce (default "gce")
    133d120
    <       --results-dir string                                         Directory to scp test results to. (default "/tmp/")
    142,145d128
    <       --ssh-env string                                             Use predefined ssh options for environment.  Options: gce
    <       --ssh-key string                                             Path to ssh private key.
    <       --ssh-options string                                         Commandline options passed to ssh.
    <       --ssh-user string                                            Use predefined user for ssh.
    160,161d142
    <       --target-build-arch string                                   Target architecture for the test artifacts for dockerized build (default "linux/amd64")
    <       --test-timeout duration                                      How long (in golang duration format) to wait for ginkgo tests to complete. (default 45m0s)
    196d176
    <       --test_args string                                           Space-separated list of arguments to pass to Ginkgo test runner.
    198d177
    <       --use-dockerized-build                                       Use dockerized build for test artifacts
2026-05-20 12:00:01 +02:00
Patrick Ohly
d97b67d97a e2e node: support running the test binary under a debugger
Single-stepping interactively through a test can be useful to understand what's
happening and to investigate the state at each step.

Similar support was added early to hack/ginkgo-e2e.sh, so the same env variable
is used again.
2024-04-16 11:46:28 +02:00
Ike Ma
e21cf9a54e Setup e2e_node to support testing on ARM64
* Enable dockerized build with --use-dockerized-build=true
* Build and create test artifacts for ARM64 with --target-build-arch=arm64
* Prepull multi-arch ready container image
* Download ARM64 binaries/packages if running on ARM64 machine
2023-05-20 00:07:44 +00:00
Danielle Lancashire
a4cf3a90a2 e2e_node: support passing kubelet-config-file to local runs 2021-11-02 15:10:29 +01:00
Kubernetes Prow Robot
f35e587087
Merge pull request #99899 from hasheddan/update-node-e2e-note
Update dependencies in local node test runner
2021-05-13 03:54:25 -07:00
Amim Knabben
0341e4c2f3 Enabling runtime config on E2E node tests 2021-03-08 15:45:06 -05:00
hasheddan
b85fbfc2b9
Update dependencies in local node test runner
Updates comment on building dependencies step in the local node test
runner to reflect the binaries that are actually produced.

Signed-off-by: hasheddan <georgedanielmangum@gmail.com>
2021-03-06 10:41:18 -06:00
Benjamin Elder
56e092e382 hack/update-bazel.sh 2021-02-28 15:17:29 -08:00
Davanum Srinivas
07d88617e5
Run hack/update-vendor.sh
Signed-off-by: Davanum Srinivas <davanum@gmail.com>
2020-05-16 07:54:33 -04:00
Davanum Srinivas
442a69c3bd
switch over k/k to use klog v2
Signed-off-by: Davanum Srinivas <davanum@gmail.com>
2020-05-16 07:54:27 -04:00
Zhen Wang
6df207bdaa allows configuring NPD image version in node e2e test and fix the test 2019-02-26 21:29:50 -08:00
Dmitry Rozhkov
43fce8d6e4 e2e-node-tests: fix path to system specs
e2e-node tests may use custom system specs for validating nodes to
conform the specs. The functionality is switched on when the tests
are run with this command:

    make SYSTEM_SPEC_NAME=gke test-e2e-node

Currently the command fails with the error:

    F1228 16:12:41.568836   34514 e2e_node_suite_test.go:106] Failed to load system spec: open /home/rojkov/go/src/k8s.io/kubernetes/k8s.io/kubernetes/cmd/kubeadm/app/util/system/specs/gke.yaml: no such file or directory

Move the spec file under `test/e2e_node/system/specs` and introduce a single
public constant referring the file to use instead of multiple private constants.
2019-01-10 10:37:55 +02:00
Davanum Srinivas
954996e231
Move from glog to klog
- Move from the old github.com/golang/glog to k8s.io/klog
- klog as explicit InitFlags() so we add them as necessary
- we update the other repositories that we vendor that made a similar
change from glog to klog
  * github.com/kubernetes/repo-infra
  * k8s.io/gengo/
  * k8s.io/kube-openapi/
  * github.com/google/cadvisor
- Entirely remove all references to glog
- Fix some tests by explicit InitFlags in their init() methods

Change-Id: I92db545ff36fcec83afe98f550c9e630098b3135
2018-11-10 07:50:31 -05:00
Yuanbin.Chen
f2eee3fe2a Fix kubeadm checks import error
kubeadm checks package import path exist "kubernetes/test",
So change the import path.

  * move "k8s.io/kubernetes/test/e2e_node/system" directory file
    to "k8s.io/kubernetes/cmd/kubeadm/app/util/system"
  * change system package import path
  * remove "k8s.io/kubernetes/test/e2e_node/system" directory

Issues report link:
https://github.com/kubernetes/kubeadm/issues/976

Signed-off-by: Yuanbin.Chen <cybing4@gmail.com>
2018-07-13 14:27:46 +08:00
liz
1ec02b1cd5
Move path management from e2e_node to common test/utils directory
enables reuse of these methods for other e2e tests
2018-04-27 11:12:10 -04:00
liz
432b542218
Generated artefacts 2018-04-27 11:11:45 -04:00
Jeff Grafton
ef56a8d6bb Autogenerated: hack/update-bazel.sh 2018-02-16 13:43:01 -08:00
Jeff Grafton
efee0704c6 Autogenerate BUILD files 2017-12-23 13:12:11 -08:00
Jeff Grafton
aee5f457db update BUILD files 2017-10-15 18:18:13 -07:00
Lantao Liu
55dc6f67d3 Let local node e2e return error.
Signed-off-by: Lantao Liu <lantaol@google.com>
2017-09-29 17:46:22 +00:00
Jeff Grafton
a7f49c906d Use buildozer to delete licenses() rules except under third_party/ 2017-08-11 09:32:39 -07:00
Jeff Grafton
33276f06be Use buildozer to remove deprecated automanaged tags 2017-08-11 09:31:50 -07:00
Yang Guo
78f04e2abf Add node e2e tests for GKE environment 2017-07-23 20:59:11 -07:00
Yang Guo
22c9e23202 Supports customized system spec in the node conformance test and creates the GKE system spec 2017-07-14 09:39:19 -07:00
Mike Danese
a05c3c0efd autogenerated 2017-04-14 10:40:57 -07:00
Jeff Grafton
20d221f75c Enable auto-generating sources rules 2017-01-05 14:14:13 -08:00
Mike Danese
161c391f44 autogenerated 2016-12-29 13:04:10 -08:00
Mike Danese
c87de85347 autoupdate BUILD files 2016-12-12 13:30:07 -08:00
Random-Liu
919935beec Remove sudo in test suite and run test with sudo. 2016-11-07 15:27:53 -08:00
Mike Danese
763c4987f2 autogenerated 2016-10-24 14:47:27 -07:00
Mike Danese
0ea5904c23 rename test/e2e_node/build/ to builder/ 2016-10-24 14:47:26 -07:00
Mike Danese
3b6a067afc autogenerated 2016-10-21 17:32:32 -07:00
Paul Morie
3539993ee0 Make node E2E tests more transparent 2016-09-20 21:55:41 -04:00
Random-Liu
afb780d4ee Move utilities into different packages. Add local and remove runner. 2016-08-24 20:18:45 -07:00