@@ -72,7 +72,7 @@ def test_make_whitelist_condition(self):
7272 def test_parse_legacy_file (self ):
7373 """Test that aprsing a legacy file works."""
7474 filename = os .path .join (os .path .dirname (__file__ ), 'files' , 'file1.split' )
75- splits = LocalSplitSynchronizer ._read_splits_from_legacy_file (filename )
75+ splits = LocalSplitSynchronizer ._read_feature_flags_from_legacy_file (filename )
7676 assert len (splits ) == 2
7777 for split in splits .values ():
7878 assert isinstance (split , Split )
@@ -84,7 +84,7 @@ def test_parse_legacy_file(self):
8484 def test_parse_yaml_file (self ):
8585 """Test that parsing a yaml file works."""
8686 filename = os .path .join (os .path .dirname (__file__ ), 'files' , 'file2.yaml' )
87- splits = LocalSplitSynchronizer ._read_splits_from_yaml_file (filename )
87+ splits = LocalSplitSynchronizer ._read_feature_flags_from_yaml_file (filename )
8888 assert len (splits ) == 4
8989 for split in splits .values ():
9090 assert isinstance (split , Split )
@@ -116,44 +116,44 @@ def test_update_splits(self, mocker):
116116 parse_legacy .reset_mock ()
117117 parse_yaml .reset_mock ()
118118 sync = LocalSplitSynchronizer ('something' , storage_mock )
119- sync ._read_splits_from_legacy_file = parse_legacy
120- sync ._read_splits_from_yaml_file = parse_yaml
119+ sync ._read_feature_flags_from_legacy_file = parse_legacy
120+ sync ._read_feature_flags_from_yaml_file = parse_yaml
121121 sync .synchronize_splits ()
122122 assert parse_legacy .mock_calls == [mocker .call ('something' )]
123123 assert parse_yaml .mock_calls == []
124124
125125 parse_legacy .reset_mock ()
126126 parse_yaml .reset_mock ()
127127 sync = LocalSplitSynchronizer ('something.yaml' , storage_mock )
128- sync ._read_splits_from_legacy_file = parse_legacy
129- sync ._read_splits_from_yaml_file = parse_yaml
128+ sync ._read_feature_flags_from_legacy_file = parse_legacy
129+ sync ._read_feature_flags_from_yaml_file = parse_yaml
130130 sync .synchronize_splits ()
131131 assert parse_legacy .mock_calls == []
132132 assert parse_yaml .mock_calls == [mocker .call ('something.yaml' )]
133133
134134 parse_legacy .reset_mock ()
135135 parse_yaml .reset_mock ()
136136 sync = LocalSplitSynchronizer ('something.yml' , storage_mock )
137- sync ._read_splits_from_legacy_file = parse_legacy
138- sync ._read_splits_from_yaml_file = parse_yaml
137+ sync ._read_feature_flags_from_legacy_file = parse_legacy
138+ sync ._read_feature_flags_from_yaml_file = parse_yaml
139139 sync .synchronize_splits ()
140140 assert parse_legacy .mock_calls == []
141141 assert parse_yaml .mock_calls == [mocker .call ('something.yml' )]
142142
143143 parse_legacy .reset_mock ()
144144 parse_yaml .reset_mock ()
145145 sync = LocalSplitSynchronizer ('something.YAML' , storage_mock )
146- sync ._read_splits_from_legacy_file = parse_legacy
147- sync ._read_splits_from_yaml_file = parse_yaml
146+ sync ._read_feature_flags_from_legacy_file = parse_legacy
147+ sync ._read_feature_flags_from_yaml_file = parse_yaml
148148 sync .synchronize_splits ()
149149 assert parse_legacy .mock_calls == []
150150 assert parse_yaml .mock_calls == [mocker .call ('something.YAML' )]
151151
152152 parse_legacy .reset_mock ()
153153 parse_yaml .reset_mock ()
154154 sync = LocalSplitSynchronizer ('yaml' , storage_mock )
155- sync ._read_splits_from_legacy_file = parse_legacy
156- sync ._read_splits_from_yaml_file = parse_yaml
155+ sync ._read_feature_flags_from_legacy_file = parse_legacy
156+ sync ._read_feature_flags_from_yaml_file = parse_yaml
157157 sync .synchronize_splits ()
158158 assert parse_legacy .mock_calls == [mocker .call ('yaml' )]
159159 assert parse_yaml .mock_calls == []
0 commit comments