That syncs the Neutron code with the latest neutron-lib version
released (3.8.0).
This patch also adds the "network.ha" definition extension to
the tests core plugin.
NOTE: both LP bugs must be fixed in one patch to fix the unit
tests CI job.
Closes-Bug: #2033493
Closes-Bug: #2033508
Change-Id: Ie22d9bcb943205e20380b92dc33d48f398a86470
neutron recently merged a commit enabling secure rbacs by default [1].
However this commit breaks the unittests of neutron-dynamic-routing.
To fix this we run multiple calls as admin, to allow them to succeed.
[1]: 670cc383e0
Closes-Bug: 2019097
Change-Id: Iadc9b819ce4aaf6029e77f53ce0616aa70119c70
* Updated callback functions port_callback,
floatingip_update_callback to include payload
* Fixed unit test cases
Change-Id: I84956d86ea45039a8841b2b1f4f02bf373efcef5
Signed-off-by: Manu B <manu.b@est.tech>
floating_ip_address may be a netaddr.IPAddress, and using '+'
to append the /32 suffix raises a TypeError. Explicitly convert to
string before appending the suffix.
Additionally, introduce a unit test case for floatingip_update_callback
to test that the error does not re-appear.
Closes-Bug: #1924237
Signed-off-by: Aggelos Kolaitis <akolaitis@admin.grnet.gr>
Change-Id: I98d266fb986649f1d14969c968baa2f93b469f73
With the removal of Python 2.x we can remove the unittest2 compat
wrappers and switch to assertCountEqual instead of assertItemsEqual
We have been able to use them since then, because
testtools required unittest2, which still included it. With testtools
removing Python 2.7 support [3][4], we will lose support for
assertItemsEqual, so we should switch to use assertCountEqual.
[1] - https://bugs.python.org/issue17866
[2] - https://hg.python.org/cpython/rev/d9921cb6e3cd
[3] - testing-cabal/testtools#286
[4] - testing-cabal/testtools#277
Change-Id: If5dc6ebffc7b4f031b0350a4fe77a660a1e7becf
With python3.x, classes can use 'metaclass=' instead of
'six.add_metaclass', 'six.integer_type' can be replaced
by 'int', 'six.string_type' and 'six.text_type' are just
'str'.
Change-Id: I40a020aa4a8e69a8dd7e800352dc54a9e694d500
Now that we no longer support py27, we can use the standard library
unittest.mock module instead of the third party mock lib.
Change-Id: Ic767e59531bc2515cc1c20675792fe88300e3f30
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
This patch switches from legacy job to a Zuul v3 job inheriting from
neutron-functional job definition.
Also cleaning up relevant files for legacy job
Change-Id: I419c98d58637d57c3a2436630dd787b17f9027d5
This patch removes all tempest tests from neutron-dynamic-routing
repository as all of them are now moved to neutron-tempest-plugin repo.
It also removes all tempest job definitions which are now replaced by
job neutron-tempest-plugin-dynamic-routing defined in
neutron-tempest-plugin repo directly.
Change-Id: I94a443c92fe2317ba2591ae3a227ec8df82ec294
This change ensures all CI jobs run against neutron-dynamic-routing
run with python 3 and all test code is compatible with python 3.
Change-Id: I77f940dca9239d710bb146e8cdf1d6058f2fbdd4
This patch removes all use of common_db_mixin. All methods of that
class are available in some form from neutron-lib and we are removing
the mixing from neutron soon.
Change-Id: I80d17a491d4468a94f4ae184f1b453f41cdf92a2
The BGP service plugin will automatically re-schedule BGP speakers
that are unscheduled with a periodic job. This introduces a race
condition that the basic scenario test job needs to account for. This
change causes the test_remove_add_speaker_agent() test to ignore
any DrAgentAssociationError when attempting to explicitly reschedule
a BGP speaker that has just unscheduled. Since the content of the
test is not affected by catching and ignoring these errors, we can
safely ignore the error while enabling the test to pass consistently.
Change-Id: I10b11ae52b36552d448cecaea03cfa1baaca026a
Closes-Bug: #1820293
In such case docker.io should be installed. It happens e.g. on
Ubuntu 18.04.
In gate_hook script there was code to handle such case when
docker-engine isn't available but grep used there wasn't
very strict and it was passing because package
"golang-github-docker-engine-api-dev" matched results.
Now it will look only for "docker-engine" package and if it will
not be available, "docker.io" will be installed.
Change-Id: I805761ba4523e71a5aa06f6f6667e801184824df
Closes-Bug: #1818628
This change adds DVR-aware announcements for routable fixed IP's
to be sent, thereby routing traffic directly to the appropriate
compute node instead of the centralized router on the network node.
Change-Id: I3aecdd7979dba97dab12a6550655c90a57f56cb3
Partial-Bug: #1775250
This change enables all capabilties regardless of peer address
family, thereby enabling announcement of IPv6 prefixes over IPv4
sessions and vice-versa. Peers can opt in/out with capabilities
configured on the remote end of the session.
Change-Id: I7b241cdfddcecbdd8cdde2e88de35b9be6982451
Closes-Bug: #1784590
We recently removed nenutron.common.rpc [1] as the rpc module lives in
neutron-lib now. This project was missed because I didn't find
neutron.common.rpc as an import. This patch switches rpc uses over to
neutron-lib.
This also addresses an issue where toxenv fails when it encounters a
non-empty __pycache__ directory. This adjusts the options passed to
find so that it is tolerant of this scenario and allows tox runs to
proceed.
[1] https://review.openstack.org/#/c/634790/
Change-Id: Ice83f7574f146436e3db045693b530f0cfeda049
When a bgp-dragent is deployed with enable_new_services
set to False so that the agent is disabled upon creation
the first attempt to enable it again throws an error but
the second time works, see the bug report.
Change-Id: If77e2035d0c12d0391ab9c38054bf2e0d24dac4a
Closes-Bug: 1799455
This change causes neutron-dynamic-routing to stop consuming Ryu
in favor of os-ken. os-ken becomes the reference implementation
for BGP services and neutron-dynamic-routing no longer has a
dependency on Ryu.
Partially-Implements: blueprint ryu-framework-maintenace-transition
Change-Id: I4a68440809cad5de2d6d191f7211d68b542672e5
Because:
- They are not necessary.
- Neutron agent scheduler code (reschedule_resources_from_down_agents)
seems to (correctly) assume each get_admin_context() call returns
a fresh context. This mocking breaks it.
- Right now, Neutron agentdb uses the new engine facade [1] and
Neutron agent scheduler doesn't. It causes caching issue in our
unit tests. (See the Related-Bug) Stopping reusing contexts
(thus sessions) would prevent the issue.
[1] https://review.openstack.org/#/c/611462/
Related-Bug: #1803745
Change-Id: Ia986f98f8bda9c7cde33af3dfdf2e45a2685fd6d
In python3.6 the path used by os.path.join can be either
a string or bytes, so mock the neutron.common.config.init
to return a string so the tests pass with python3.6.
Change-Id: I10b399edb76b2ed3a2a235f9f4ec278ef94c4251
Signed-off-by: Chuck Short <chucks@redhat.com>
More in-depth type checking of args in Python 3.6 causes issues
with the current approach to patching sys.argv for agent unit
tests; Directly patch argv with the required test arguments
rather than using return_value (which does not really do what
the test assumes it does).
Change-Id: I8966323e3f0853351fe27207ae63901c2f9f351a
Reserving subnet CIDR make impossible to reuse the same
CIDR for a subnet twice for the test case class.
Change-Id: Ia32f0e3fea509d1eb0074f5d4bdaf5b02b6dcae0
Depends-On: I421dd28999086ee0af9246121f4f033291e341b4
Closes-Bug: #1766702
The create_connection function in neutron.common.rpc is just an alias to
Connection. This patch switches to the later so we can remove the former
in: https://review.openstack.org/#/c/560130
Change-Id: Ie8eaca442fa2872fe061f997898d9cd7d9195c9d
Since a separate job has not been created [0], move the scenario test
into the basic directory so that it will be executed there.
Set TEMPEST_CONCURRENCY=1 for the basic scenario job in order to avoid
resource collisions.
[0] https://review.openstack.org/529256
Change-Id: Idbf2739a585473fdf1d364ad1ee263ad359fd750
When get_bgp_speaker_with_advertised_routes() collects the data for BGP
peers, it needs to include the auth_type field, otherwise adding the
speaker to an agent will fail.
Change-Id: I668397be4a531ba5c0628eb23df9a84d0de8c28c
Closes-Bug: 1750121
Remove unnecessary settings of None in the floating IP
creation.
This is now dealt correctly with by neutron.
Change-Id: Ifa7195bc0c58eca077579039705bb1738f3d362e
DB validations need to make sure that the value is True or False.
'0' was causing the unit tests to fail.
Change-Id: I0af74c88ce4c4e9d117ea5ff3394eec5be27ecf7
* https://review.openstack.org/519310 syncs the code from neutron
project to neutron-tempest-plugin repo and it is better to
depend on new one in order to avoid the breakage.
Depends-On: I9962fd5aa9a13f315208255e2cc5f599871a6f53
Change-Id: I34efe893b93240c4689de1dda978209926022dfd
Now neutron_dynamic_routing supports 2 byte AS numbers only.
This patch expands AS numbers constraint so that it supports
4 byte AS numbers. It expects that operators use asplain
notation to set AS numbers[1]. That's backward compatible with
existing 2 byte AS numbers.
[1]: https://tools.ietf.org/html/rfc5396
Change-Id: I06ae0c42d983e88e1f38c501d5c85a7956f195ad
Closes-Bug: #1573092
The external network extension's API definition was rehomed into
neutron-lib with I9933b91d1e82db3891b3b72f06e94316e56a4f15 and
broke our unittests.
Change-Id: Ib184871ac7ec5cd09cfb26d911cec8d9ae6fca7e
The tempest.test.is_extension_enabled() has moved to
tempest.common.utils.is_extension_enabled() in Pike.
Change-Id: I8fb12f913f187e4f0208438e7f39b2691f0dd4f3
A recent change in the neutron repository changed the
import statements for external_process, fixing fallout.
Fix post gate hook to accommodate for new os-testr.
New versions now use .stestr instead of previous .testrepository
directory.
Related-bug: #1716746
Change-Id: Iba7579f8de63c6ce87d95167918fc46979702a35
We have seen in Dragonflow tempest tests that docker bridges do not
always clean-up correctly, and this causes false-positive errors.
This change modifies the name of the bridge to be unique for each test.
This way, if a test fails to clean up, it will not affect the other
tests.
Change-Id: I869c6dc798cd1cc20376023481518e7a03b71fde