Commit Graph

100 Commits

Author SHA1 Message Date
AkiraFukushima 36acadca59 Fill Role names in kops-controller-config instead of instance profile names when it is specified
The role names are checked in node bootstrap.
If profile names are provided, bootstrap will fail.
Because profile name and role name do not always mactch in AWS IAM
2021-02-11 14:28:49 +09:00
Ciprian Hacman d5bee0b867 Update integration test for ExternalLoadBalancers 2020-11-21 21:45:57 +02:00
Peter Rifel 11bf3ff202
Add missing cloudmock functionality for enabling lifecycle integration test on complex cluster 2020-10-30 10:06:36 -05:00
Ole Markus With 7c8ff94631 Make setupmockopenstack standalone 2020-10-01 19:15:39 +02:00
Ole Markus With 6797998ac1 Consolidate all buildMinimalClusters into a generic test cluster builder 2020-09-19 19:55:19 +02:00
Ole Markus With 5e7ec64347 Move abs resolution a bit earlier to make it clear where we are looking for golden output 2020-09-05 20:10:43 +02:00
Ole Markus With 8e5e3d4ea5 Mock create server should associate with mock ports 2020-08-22 22:08:02 +02:00
Ole Markus With 29682700c7 Don't use nova for glance mocks
Fetching images through nova is deprecated and removed in newer versions
of the compute API. Mocks now reflect this behavior.
2020-08-21 10:18:52 +02:00
Peter Rifel 4d9f0128a3
Upgrade to klog2
This splits up the kubernetes 1.19 PR to make it easier to keep up to date until we get it sorted out.
2020-08-16 20:56:48 -05:00
Peter Rifel 6991655921
Add openstack integration test.
This will create / update / update / delete an openstack cluster using cloudmock, ensuring there are no lingering changes reported or orphaned resources
2020-08-10 15:22:49 -05:00
John Gardiner Myers d8970b93e1 Issue kube-controller-manager cert in nodeup 2020-06-09 22:45:19 -07:00
Justin Santa Barbara 35c6056fb2 Create golden image test for nodeup kube-apiserver
The building of the manifests for nodeup tasks can be a little opaque;
create a test to verify and expose what is happening.
2020-05-18 06:42:16 -04:00
Peter Rifel a0e1672cdc add terraform testing 2020-03-31 14:50:45 -05:00
Justin SB cf5c53c87d
Add tests for manifest normalization
(The tests are split out for easier cherry-picking, should we choose to)
2020-01-11 22:41:18 -05:00
tanjunchen 7e25f9831d nodeup/pkg/ pkg/ staticcheck 2019-12-31 15:03:39 +08:00
Justin Santa Barbara 58dccb0c5d dev: hack/update-expected.sh should generate missing file
Don't treat a failure to read a file as an error, if we are supposed
to be generating that file.
2019-12-14 22:14:39 -05:00
Justin SB 97f552778f
Add env vars, update tests 2019-09-25 12:48:13 -04:00
Justin SB 1580d4c82b
Update tests to use k8s >= 1.14
Where tests are using a version of k8s that is now really deprecated,
replace it with k8s 1.14.0.
2019-09-14 13:58:50 -04:00
mikesplain 9e55b8230a Update copyright notices
Also cleans some white spaces
2019-09-09 14:47:51 -04:00
Justin SB 512378b335
Rationalize golden-output comparison
Create a single helper function: AssertMatchesFile

Also a few output files that weren't consistent.
2019-07-21 23:08:48 -04:00
Justin SB 76d03b3f71
Generated files: glog -> klog 2019-05-06 12:56:03 -04:00
Justin SB 3e33ac7682
Change code from glog to klog
We don't call klog.InitFlags yet, because that will cause a flag
redefinition error until we get everyone to stop using glog.  That
will happen when we update to k8s 1.13.
2019-05-06 12:54:51 -04:00
Gennady Trafimenkov acf9c9f016 Update bazel configuration 2019-03-03 16:11:33 +03:00
Gennady Trafimenkov 15bd566746 Correcly handle CRLF in the manifest
kops replace/create/delete now correctly handle crlf in the manifest.

This fixes issue #6532
2019-03-03 14:33:49 +03:00
Justin SB 4aa2498203
Rationalize deserialiation code
Put it all through kopscodecs.Decode, so that we can rewrite the API
group more easily in a subsequent PR.
2018-12-21 13:59:50 -05:00
Justin Santa Barbara 9e765a75bf Generate much smaller keys in integration tests
We expose the default key size, and temporarily set it to 512 (from
2048) during testing.  This is much faster, and key generation was the
primary bottleneck.
2018-10-03 08:33:46 -07:00
Justin Santa Barbara 666e290983
Merge pull request #5547 from justinsb/etcd_manager_tests
Add test for etcd-manager output
2018-09-22 08:29:30 -07:00
Justin Santa Barbara 7cf432fcba Add test for etcd-manager output
We need to get this under test coverage so we can start changing it confidently!
2018-09-14 08:46:32 -04:00
Naresh Kumar Amrutham 97b258ca64 update build files 2018-08-17 13:12:03 -07:00
Naresh Kumar Amrutham 504414dd1c include tests 2018-08-17 13:04:28 -07:00
k8s-ci-robot a57a6de4a8
Merge pull request #5139 from justinsb/fix_subnet_egress_indexing
Fix issue where we assumed that private zone were in order
2018-06-09 09:27:01 -07:00
k8s-ci-robot 1157789a63
Merge pull request #4723 from sroylance/testing-windows
hacks for tests on windows
2018-06-02 11:22:57 -07:00
Justin Santa Barbara bc79f0a69b tests: failing test when multiple egress
Also requires that the subnets be out of order, which is likely why we
didn't hit it in practice.
2018-05-10 13:28:05 -04:00
Justin Santa Barbara afa0577749 Check tags in lifecycle tests
We want to make sure that everything owned is tagged as such, and that
some shared resources (in particular subnets) are tagged as such.
2018-03-25 15:55:44 -04:00
Justin Santa Barbara e81e53b5b2 mockec2: allow elastic ip tagging 2018-03-25 00:01:41 -04:00
Justin Santa Barbara 0711df9de4 Improve logic around VPC detection
Issue #4265
2018-03-19 18:15:37 -04:00
Stephen Roylance 70815ebaf9 hacks for tests on windows 2018-03-19 16:34:36 -04:00
Justin Santa Barbara 6ff56e2f05 Fix shared network objects
RouteTables should be created (and owned) only for non-shared subnets.
2018-03-18 17:09:30 -04:00
Justin Santa Barbara 7af6f42e8b Tests: create vpc-12345678 & nat-12345678 2018-03-15 20:11:54 -04:00
Justin Santa Barbara c121e7f14e Create lifecycle test against AWS mocks
We create a cluster, run kops update, then run kops update again.  We
expect no changes on the second update.
2018-03-11 17:04:30 -04:00
Dennis Webb 5855787574 returns latest image if more than 1 found 2018-01-25 10:04:12 -06:00
Justin Santa Barbara a8a83f3ce9 Update gazelle 2017-12-14 01:31:28 -05:00
Peter Rifel 358e2e222c Create mock igw in integration tests 2017-12-07 16:38:06 -08:00
Arto Jantunen 53669b8217 Make ELB somewhat mockable 2017-11-28 11:48:57 +02:00
chrislovecnm 609e268a1d gazelle updates with new bazel version 2017-11-05 17:41:53 -07:00
Justin Santa Barbara 19677523c0 Mock kops version in tests
This avoids having to update the tests every time our version changes.
2017-10-10 11:11:57 -04:00
Justin Santa Barbara 0143be7c4f autogen: BUILD and BUILD.bazel 2017-10-02 14:27:21 -04:00
Justin Santa Barbara 055f510c6f Create minimal mock GCECloud, first test
We test create cluster - we actually have an issue with the length of
the names on longer cluster names; first step is to get test coverage.
2017-09-16 11:02:30 -04:00
Justin Santa Barbara 4767ee9e31 Read the channel from the local filesystem during tests
Another step towards working totally offline (which may never be fully
achievable, because of the need to hash assets).  But should ensure that
when we update the stable channel, we are testing against that version
in the tests, otherwise it is easy to break master.
2017-08-09 21:26:21 -04:00
Justin Santa Barbara 1965a4be49 Updates to fix unit tests 2017-07-08 18:46:01 -04:00