<feed xmlns='http://www.w3.org/2005/Atom'>
<title>vyos-cloud-init.git/cloudinit/distros/tests, branch current</title>
<subtitle> (mirror of https://github.com/vyos/vyos-cloud-init.git)
</subtitle>
<id>https://git.amelek.net/vyos/vyos-cloud-init.git/atom?h=current</id>
<link rel='self' href='https://git.amelek.net/vyos/vyos-cloud-init.git/atom?h=current'/>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/'/>
<updated>2021-12-03T20:11:46+00:00</updated>
<entry>
<title>Reorganize unit test locations under tests/unittests (#1126)</title>
<updated>2021-12-03T20:11:46+00:00</updated>
<author>
<name>Brett Holman</name>
<email>bholman.devel@gmail.com</email>
</author>
<published>2021-12-03T20:11:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=039c40f9b3d88ee8158604bb18ca4bf2fb5d5e51'/>
<id>urn:sha1:039c40f9b3d88ee8158604bb18ca4bf2fb5d5e51</id>
<content type='text'>
This attempts to standardize unit test file location under test/unittests/
such that any source file located at cloudinit/path/to/file.py may have a
corresponding unit test file at test/unittests/path/to/test_file.py.

Noteworthy Comments:
====================
Four different duplicate test files existed:
test_{gpg,util,cc_mounts,cc_resolv_conf}.py
Each of these duplicate file pairs has been merged together. This is a
break in git history for these files.

The test suite appears to have a dependency on test order. Changing test
order causes some tests to fail. This should be rectified, but for now
some tests have been modified in
tests/unittests/config/test_set_passwords.py.

A helper class name starts with "Test" which causes pytest to try
executing it as a test case, which then throws warnings "due to Class
having __init__()".  Silence by changing the name of the class.

# helpers.py is imported in many test files, import paths change
cloudinit/tests/helpers.py -&gt; tests/unittests/helpers.py

# Move directories:
cloudinit/distros/tests -&gt; tests/unittests/distros
cloudinit/cmd/devel/tests -&gt; tests/unittests/cmd/devel
cloudinit/cmd/tests -&gt; tests/unittests/cmd/
cloudinit/sources/helpers/tests -&gt; tests/unittests/sources/helpers
cloudinit/sources/tests -&gt; tests/unittests/sources
cloudinit/net/tests -&gt; tests/unittests/net
cloudinit/config/tests -&gt; tests/unittests/config
cloudinit/analyze/tests/ -&gt; tests/unittests/analyze/

# Standardize tests already in tests/unittests/
test_datasource -&gt; sources
test_distros -&gt; distros
test_vmware -&gt; sources/vmware
test_handler -&gt; config        # this contains cloudconfig module tests
test_runs -&gt; runs</content>
</entry>
<entry>
<title>Update test characters in substitution unit test (#893)</title>
<updated>2021-05-11T16:34:29+00:00</updated>
<author>
<name>James Falcon</name>
<email>TheRealFalcon@users.noreply.github.com</email>
</author>
<published>2021-05-11T16:34:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=899bfaa9d6bfab1db0df99257628ca1f6febff60'/>
<id>urn:sha1:899bfaa9d6bfab1db0df99257628ca1f6febff60</id>
<content type='text'>
In newer versions of python, when using urllib.parse, lines containing
newline or tab characters now get sanitized. This caused a unit test to
fail.

See https://bugs.python.org/issue43882</content>
</entry>
<entry>
<title>Ability to hot-attach NICs to preprovisioned VMs before reprovisioning (#613)</title>
<updated>2020-11-23T15:04:05+00:00</updated>
<author>
<name>aswinrajamannar</name>
<email>39812128+aswinrajamannar@users.noreply.github.com</email>
</author>
<published>2020-11-23T15:04:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=a4d0feb050e32277a218e45bfb6a496d26ff46d0'/>
<id>urn:sha1:a4d0feb050e32277a218e45bfb6a496d26ff46d0</id>
<content type='text'>
Adds the ability to run the Azure preprovisioned VMs as NIC-less and
then hot-attach them when assigned for reprovision.

The NIC on the preprovisioned VM is hot-detached as soon as it reports
ready and goes into wait for one or more interfaces to be hot-attached.
Once they are attached, cloud-init gets the expected number of NICs (in
case there are more than one) that will be attached from IMDS and waits
until all of them are attached. After all the NICs are attached,
reprovision proceeds as usual.</content>
</entry>
<entry>
<title>networking: refactor wait_for_physdevs from cloudinit.net (#466)</title>
<updated>2020-07-14T17:31:13+00:00</updated>
<author>
<name>Daniel Watkins</name>
<email>oddbloke@ubuntu.com</email>
</author>
<published>2020-07-14T17:31:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=25289087e44c9c74543248519e37ca1f11b8a711'/>
<id>urn:sha1:25289087e44c9c74543248519e37ca1f11b8a711</id>
<content type='text'>
* Refactor `cloudinit.net.wait_for_physdevs` to `cloudinit.distros.networking.Networking.wait_for_physdevs`
* Split the Linux-specific `udevadm_settle` call out to a separate abstract `Networking.settle` method; implement it on `LinuxNetworking` and add a `NotImplementedError` implementation to `BSDNetworking`
* Modify `wait_for_physdevs`s one callsite to use the new location

LP: #1884626</content>
</entry>
<entry>
<title>Disable ec2 mirror for non aws instances (#390)</title>
<updated>2020-06-30T22:25:26+00:00</updated>
<author>
<name>lucasmoura</name>
<email>lucas.moura@canonical.com</email>
</author>
<published>2020-06-30T22:25:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=3fcdacc8995d6908858aceaf1da7ee5ff090fc04'/>
<id>urn:sha1:3fcdacc8995d6908858aceaf1da7ee5ff090fc04</id>
<content type='text'>
For versions before 20.2, we allowed the use of ec2 mirrors if the datasource availability_zone matches one of the ec2 regions. We are now updating that behavior to allow allow the use of ec2 mirrors on ec2 instances or if the user directly passes an an ec2 mirror url through #cloud-config apt directives.

LP: #1456277</content>
</entry>
<entry>
<title>networking: refactor is_physical from cloudinit.net (#457)</title>
<updated>2020-06-30T18:19:38+00:00</updated>
<author>
<name>Daniel Watkins</name>
<email>oddbloke@ubuntu.com</email>
</author>
<published>2020-06-30T18:19:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=882f1a5f2d5bafd08e6900a2782c3affa67c9d86'/>
<id>urn:sha1:882f1a5f2d5bafd08e6900a2782c3affa67c9d86</id>
<content type='text'>
As the first refactor PR, this also includes the initial structure for tests.

LP: #1884619</content>
</entry>
<entry>
<title>distros: drop leading/trailing hyphens from mirror URL labels (#296)</title>
<updated>2020-03-31T21:04:17+00:00</updated>
<author>
<name>Daniel Watkins</name>
<email>oddbloke@ubuntu.com</email>
</author>
<published>2020-03-31T21:04:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=1bbc4908ff7a2be19483811b3b6fee6ebc916235'/>
<id>urn:sha1:1bbc4908ff7a2be19483811b3b6fee6ebc916235</id>
<content type='text'>
* distros/tests/test_init: drop needless brackets/indentation

* distros: drop leading/trailing hyphens from mirror URL labels</content>
</entry>
<entry>
<title>distros: replace invalid characters in mirror URLs with hyphens (#291)</title>
<updated>2020-03-31T17:52:21+00:00</updated>
<author>
<name>Daniel Watkins</name>
<email>oddbloke@ubuntu.com</email>
</author>
<published>2020-03-31T17:52:21+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=c478d0bff412c67280dfe8f08568de733f9425a1'/>
<id>urn:sha1:c478d0bff412c67280dfe8f08568de733f9425a1</id>
<content type='text'>
This modifies _get_package_mirror_info to convert the hostnames of generated mirror URLs to their IDNA form, and then iterate through them replacing any invalid characters (i.e. anything other than letters, digits or a hyphen) with a hyphen.

This commit introduces the following changes in behaviour:

* generated mirror URLs with Unicode characters in their hostnames will have their hostnames converted to their all-ASCII IDNA form
* generated mirror URLs with invalid-for-hostname characters in their hostname will have those characters converted to hyphens
* generated mirror URLs which cannot be parsed by `urllib.parse.urlsplit` will not be considered for use
  * other configured patterns will still be considered
  * if all configured patterns fail to produce a URL that parses then the fallback mirror URL will be used

LP: #1868232</content>
</entry>
<entry>
<title>distros/tests/test_init: add tests for _get_package_mirror_info (#272)</title>
<updated>2020-03-25T13:44:16+00:00</updated>
<author>
<name>Daniel Watkins</name>
<email>oddbloke@ubuntu.com</email>
</author>
<published>2020-03-25T13:44:16+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=c5e949c02a1d5226ae9b1cb39846db19d223c6c2'/>
<id>urn:sha1:c5e949c02a1d5226ae9b1cb39846db19d223c6c2</id>
<content type='text'>
</content>
</entry>
</feed>
