File tree Expand file tree Collapse file tree 1 file changed +29
-0
lines changed
Expand file tree Collapse file tree 1 file changed +29
-0
lines changed Original file line number Diff line number Diff line change @@ -734,3 +734,32 @@ def test_prop_range(app: TileServer) -> None:
734734 assert response .status_code == 200
735735 # should be back to no scaling
736736 assert layer .renderer .score_fn (0.5 ) == 0.5
737+
738+
739+ def test_registration (
740+ empty_app : TileServer , tmp_path : Path , remote_sample : Callable
741+ ) -> None :
742+ """Test registering slides."""
743+ data = make_simple_dat ()
744+ joblib .dump (data , tmp_path / "test.dat" )
745+ with empty_app .test_client () as client , empty_app .test_client () as client2 :
746+ setup_app (client )
747+ response = client .put (
748+ "/tileserver/slide" ,
749+ data = {"slide_path" : safe_str (remote_sample ("svs-1-small" ))},
750+ )
751+ assert response .status_code == 200
752+
753+ # Open new window with other slide...
754+ setup_app (client2 )
755+ response = client2 .put (
756+ "/tileserver/slide" ,
757+ data = {"slide_path" : safe_str (remote_sample ("svs-1-small" ))},
758+ )
759+ assert response .status_code == 200
760+
761+ response = client2 .put (
762+ "/tileserver/overlay" ,
763+ data = {"overlay_path" : safe_str (remote_sample ("reg_disp_mha_example" ))},
764+ )
765+ assert response .status_code == 200
You can’t perform that action at this time.
0 commit comments