Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Disable some problematic tests on macOS
Browse files Browse the repository at this point in the history
matrss committed Feb 27, 2024
1 parent eed70f0 commit 2bfbb03
Showing 2 changed files with 18 additions and 1 deletion.
5 changes: 5 additions & 0 deletions tests/_test_msui/test_mscolab.py
Original file line number Diff line number Diff line change
@@ -25,6 +25,7 @@
limitations under the License.
"""
import os
import sys
import fs
import fs.errors
import fs.opener.errors
@@ -350,6 +351,10 @@ def test_handle_export(self, mockbox, qtbot):
for i in range(wp_count):
assert exported_waypoints.waypoint_data(i).lat == self.window.mscolab.waypoints_model.waypoint_data(i).lat

@pytest.mark.skipif(
sys.platform == "darwin",
reason="This test is flaky on macOS because of some cleanup error in temporary files.",
)
@pytest.mark.parametrize("name", [("example.ftml", "actionImportFlightTrackFTML", 5),
("example.csv", "actionImportFlightTrackCSV", 5),
("example.txt", "actionImportFlightTrackTXT", 5),
14 changes: 13 additions & 1 deletion tests/_test_mswms/test_wms.py
Original file line number Diff line number Diff line change
@@ -25,7 +25,7 @@
See the License for the specific language governing permissions and
limitations under the License.
"""

import sys
import os
from shutil import move

@@ -388,6 +388,12 @@ def test_import_error(self):
assert mslib.mswms.wms.mswms_settings.__file__ is not None
assert mslib.mswms.wms.mswms_auth.__file__ is not None

@pytest.mark.skipif(
sys.platform == "darwin",
reason="There is a race condition between modifying with ncap2 and asserting that the file changed where the"
" server might not see the change before the request is made, which leads to a failure of the following"
" assert.",
)
def test_files_changed(self):
def do_test():
environ = {
@@ -429,6 +435,12 @@ def do_test():
"data_access", new=watch_access):
do_test()

@pytest.mark.skipif(
sys.platform == "darwin",
reason="Changes global variables (e.g. DOCS_LOCATION) which can affect other tests depending on test order"
" (e.g. tests/_test_mswms/test_mss_plot_driver.py::Test_VSec::test_VS_gallery_template fails consistently in"
" reverse order on macOS 14).",
)
def test_gallery(self, tmpdir):
tempdir = tmpdir.mkdir("static")
docsdir = tmpdir.mkdir("docs")

0 comments on commit 2bfbb03

Please sign in to comment.