@@ -646,25 +646,15 @@ def test_alias():
646646 index1 .hset ("index1:lonestar" , mapping = {"name" : "lonestar" })
647647 index2 .hset ("index2:yogurt" , mapping = {"name" : "yogurt" })
648648
649- if os .environ .get ("GITHUB_WORKFLOW" , None ) is not None :
650- time .sleep (2 )
651- else :
652- time .sleep (5 )
653-
654- def1 = IndexDefinition (prefix = ["index1:" ], score_field = "name" )
655- def2 = IndexDefinition (prefix = ["index2:" ], score_field = "name" )
649+ def1 = IndexDefinition (prefix = ["index1:" ])
650+ def2 = IndexDefinition (prefix = ["index2:" ])
656651
657652 ftindex1 = index1 .ft ("testAlias" )
658- ftindex2 = index1 .ft ("testAlias2" )
653+ ftindex2 = index2 .ft ("testAlias2" )
659654 ftindex1 .create_index ((TextField ("name" ),), definition = def1 )
660655 ftindex2 .create_index ((TextField ("name" ),), definition = def2 )
661656
662- # CI is slower
663- try :
664- res = ftindex1 .search ("*" ).docs [0 ]
665- except IndexError :
666- time .sleep (5 )
667- res = ftindex1 .search ("*" ).docs [0 ]
657+ res = ftindex1 .search ("*" ).docs [0 ]
668658 assert "index1:lonestar" == res .id
669659
670660 # create alias and check for results
@@ -681,9 +671,6 @@ def test_alias():
681671 ftindex2 .aliasupdate ("spaceballs" )
682672 alias_client2 = getClient ().ft ("spaceballs" )
683673
684- if os .environ .get ("GITHUB_WORKFLOW" , None ) is not None :
685- time .sleep (5 )
686-
687674 res = alias_client2 .search ("*" ).docs [0 ]
688675 assert "index2:yogurt" == res .id
689676
0 commit comments