- Mar 30, 2021
-
-
Karel Koci authored
This reason for this is that we use at some point serial console only to get logs. We do not process it further. There is no reader for serial console at most of time. This change allows disable of serial console input and serial console logs are thus only logged without further propagation.
-
Karel Koci authored
This checks not only if services we want are running but also if they are enabled. The real reason for this is not to cover issue of disabled but running service as that is highly unlikely. This rather covers services that spawn actually no process but still we have to check if they are enabled and thus executed in some manner. There is a lot of such services.
-
Karel Koci authored
It should be enough to just download index for now. It checks only if we are able to access HTTP, nothing more.
-
Karel Koci authored
The issue was invalid condition as well as that if all input was consumed that linebuf stayed set to old (already consumed) value.
-
Karel Koci authored
This is negation of board mark. This should help us to limit tests not only to explicit list of boards but also do exclusion list. The immediate usage of this is in DNS resolver processes check.
-
Karel Koci authored
The idea of having one module called toolbox is simply to share common short but still little bit complicated functions in multiple tests. This also implements first test using this function. It checks if all services we expect to run after router start are actually running.
-
Karel Koci authored
It is common that tests are run with logs printed to terminal. It helps developer to see what is actually happening. The problem is that log printing interferes with terminal output. It should be safe to set level of root logger such it prints no messages for time of mterm execution.
-
Karel Koci authored
The message was being printed almost right on prepare method enter. The problem is that it was called before parent image prepare method was called. In effect this generated messages in reverse order. It also made it pretty much impossible to identify which container exactly failed to prepare as warnings for all images were printed even before any of them started actually preparing. This moves it after parent prepare method call and thus makes it so prepare messages are printed in order and right before actual work is being performed. This also gives us the option to include full container name we use for bootstrapping.
-
Karel Koci authored
Originally mterm was using just semicolon but bare semicolon is invalid in shell so it prints error. This instead passes decision of command to be used to specific Cli implementations.
-
Karel Koci authored
The nsfarm library tools can be invoked by: python3 -m nsfarm This is pretty simple but it is not directly visible, the documentation has to be investigated to found this out, as well as not exactly short. Having this short script should do us no harm.
-
Karel Koci authored
This should prevent hopefully failures when network is not yet up in the client container.
-
Karel Koci authored
It tests only if hardware type is correctly reported and if appropriate serial number is returned. This adds new requirement for configuration and that is serial number. We need this to verify that crypto-wrapper correctly returns appropriate number.
-
Karel Koci authored
This improves XML and HTML reports. It is minor expansion with required info: tested branch and target.
-
Karel Koci authored
The only possible execution right now is with serial and wan present. In reality we need lan1 as well but we have to get around that because CPU only Mox. This simply removes parameters and marks for appropriate fixtures. The effect is just less marks as well as better tests reports as they no longer report None parameters.
-
Karel Koci authored
It seems that pytest_html is now included automatically and including it second time here produces warning.
-
Karel Koci authored
This reduces user's overhead to launch tests. It uses targets filtering. This makes target specification optional. At the moment user can specify that he wants to run tests on specific board. In the future we should add filters for additional configured board features, such as presence of Wi-Fi cards or USB storage device.
-
Karel Koci authored
This not only moves target config parsing to nsfarm library but also it changes it to be implementation defined not just access to configparser.
-
- Mar 29, 2021
-
-
Karel Koci authored
This should suppress mod of the day and other messages just to make logs little bit less duplicate.
-
Karel Koci authored
-
- Mar 18, 2021
-
-
Karel Koci authored
The current tests check if appropriate profiles exists but not if they actually work. The nsfarm-root has to work when container at least starts. The problem is with nsfarm-internet. It is required to test if it is possible to access the Internet or not with that profile. That is exactly what this test does.
-
- Mar 17, 2021
-
-
Karel Koci authored
This should have been is_symlink as it checks for symlinks.
-
- Mar 16, 2021
-
-
Karel Koci authored
There was for some reason condition that only directories are listed when image hash is generated. In reality the code was prepared to handle any path and should include all paths. This removes this invalid condition and makes it so all files provided for image are included in hash calculation. This in effect makes it so new image build is triggered on any file modification.
-
- Feb 25, 2021
-
-
Karel Koci authored
The Python PEP8 specifies that exceptions should be named *Error so this renames the exceptions to match that.
-
Karel Koci authored
This is just test that checks that we have all required devices on host system. These devices are optional and additional modules are requires to be installed and loaded to kernel. At the moment only the /dev/ppp is tested there.
-
Karel Koci authored
There is change that adds device exclusivity. Only for few devices we need exclusive passtrough to container. In most cases it is enough to pass only access to that device. Another change is that there is possibility to specify parameter for images. At the moment this allows only passtrough of Unix character devices but that can be expanded in the future.
-
Karel Koci authored
The arguments of Container class changed but they were not updated here.
-
Karel Koci authored
-
Karel Koci authored
The micro terminal is minimal connection between terminal and socket. This way it can be hooked up to any socket in nsfarm and thus allowing the direct access for CLI interfaces. The primary use is to access board's serial console. This replaces serial_miniterm with simpler and more generic implementation.
-
Karel Koci authored
It turns out that nonblocking doesn't mean nonblocking in all cases. In this case when there was no input the read was blocking. The timeout set to zero solves this.
-
Karel Koci authored
This now not only makes sense becuase we have live logging it also fixes TODO pointed there, we just wait for file to appear (syslog-ng to start).
-
Karel Koci authored
-
Problem with logging trough pexpect is that we log output only when we expect it. That is when we access it trough pexpect. This means that time and synchronization when logs arrive from multiple sources can't be archived and only one source logs at the time (the one that is used currently by pexpect). This is not ideal as we are interested in situation such as restarting network interfaces that produce some logs not only on router but also in container at the same time. Synchronization on time bases in such cases is important and we can't wait for code to call pexpect to print it to logs later on. This instead utilizes sockets and by reading source immediately and just passing it to socket.
-
- Feb 22, 2021
-
-
Karel Koci authored
-
- Jan 07, 2021
-
-
Karel Koci authored
Upstream seem to have fixed invalid init script in iperf3-openrc package so now this hack is no longer required.
-
Karel Koci authored
Yeah it provides dict with fields where we are interested in name. The rest of the function does that correctly but one line does not.
-
Karel Koci authored
-
- Dec 22, 2020
-
-
Karel Koci authored
-
- Jul 16, 2020
-
-
Karel Koci authored
This replaces code that reads whole file and then updates content with function that reads file in limited chunks.
-
- Jul 15, 2020
-
-
Karel Koci authored
This is just initial minimal set of tests. Nothing big.
-
Karel Koci authored
This now separates image and container representation to two separate classes. For users it is almost the same but it makes structure of lxd module much better and improves overal readability of Container class.
-