Hi Peter.You should stub instance instead of class:�� �� ��s := Something new.�� �� ��s stub askFor...7 ������. 2017 ��. 9:18 ������������������������ "Peter Uhn��k" <i.uhnak@gmail.com> ��������������:Hi,maybe I am missing something fundamental, because this seems like an obvious scenarioI have a class Something with two methodsSomething>>askForName^ UIManager default request: 'Name'Something>>name^ self askForName , ' suffix'Now I want to mock out askForName, so I can run it automatically in tests...I've tried just stubbing it...SomethingTest>>testRenameStubSomething stub askForName willReturn: 'new'.Something new name should be: 'new suffix'however it still opens the window to ask for the name, so the original method is being called.Right now I have to stub it with metalinks, which doesn't play well with some tools (hapao)SomethingTest>>testRenameMeta| link newName |link := MetaLink newmetaObject: [ 'new' ];control: #instead.(Something >> #askForName) ast link: link.[ newName := Something new name ]ensure: [ link uninstall ].self assert: newName equals: 'new suffix'Thanks,Peter