Bug 1214879 Add a relationship performing eager load in the Port model, thus preventing the 'extend' function from performing an extra query. This patch also replaces assertTrue with assertEqual in unit tests as it needs to evaluate whether the value of the mac_learning_enabled attribute is equal to the boolean literal True, whereas assertTrue verifies that the expression passed to it evaluates to True. This means that any value but False will be enough for the test to pass, which is not correct. Change-Id: I03345ef3a125fdfa1ec7f6c3363d76efc12ced82
3.1 KiB
3.1 KiB