Added tests for fetch callback handling