@@ -35,14 +35,14 @@ def test_init_defaults(self):
3535 self .assertIsNone (target .sslcert )
3636 self .assertIsNone (target .sslkey )
3737 self .assertEqual (target .uri , 'http://localhost:1234' )
38- self .assertEqual (target .version , '2.0.0' )
38+ self .assertEqual (target .specification_version , '2.0.0' )
3939 self .assertEqual (len (target ._interactions ), 0 )
4040
4141 def test_init_custom_mock_service (self ):
4242 target = Pact (
4343 self .consumer , self .provider , host_name = '192.168.1.1' , port = 8000 ,
4444 log_dir = '/logs' , ssl = True , sslcert = '/ssl.cert' , sslkey = '/ssl.pem' ,
45- cors = True , pact_dir = '/pacts' , version = '3.0.0' ,
45+ cors = True , pact_dir = '/pacts' , specification_version = '3.0.0' ,
4646 file_write_mode = 'merge' )
4747
4848 self .assertIs (target .consumer , self .consumer )
@@ -56,7 +56,7 @@ def test_init_custom_mock_service(self):
5656 self .assertEqual (target .sslcert , '/ssl.cert' )
5757 self .assertEqual (target .sslkey , '/ssl.pem' )
5858 self .assertEqual (target .uri , 'https://192.168.1.1:8000' )
59- self .assertEqual (target .version , '3.0.0' )
59+ self .assertEqual (target .specification_version , '3.0.0' )
6060 self .assertEqual (target .file_write_mode , 'merge' )
6161 self .assertEqual (len (target ._interactions ), 0 )
6262
@@ -371,7 +371,7 @@ def test_stop_windows(self):
371371 ruby_exe = Mock (spec = Process )
372372 self .mock_Process .return_value .children .return_value = [ruby_exe ]
373373 self .mock_Pid_exists .return_value = False
374- pact = Pact (Consumer ('consumer' ), Provider ('provider' ), publish_to_broker = True )
374+ pact = Pact (Consumer ('consumer' , version = 'abc' ), Provider ('provider' ), publish_to_broker = True )
375375 pact ._process = Mock (spec = Popen , pid = 999 )
376376 pact .stop_service ()
377377
@@ -383,7 +383,8 @@ def test_stop_windows(self):
383383 ruby_exe .terminate .assert_called_once_with ()
384384 self .mock_Process .return_value .wait .assert_called_once_with ()
385385 self .mock_Pid_exists .assert_called_once_with (999 )
386- self .mock_publish .assert_called_once ()
386+ self .mock_publish .assert_called_once_with (
387+ pact , 'consumer' , 'abc' , consumer_tags = None , tag_with_git_branch = False )
387388
388389 def test_stop_fails_posix (self ):
389390 self .mock_platform .return_value = 'Linux'
0 commit comments