Anomaly detection on attributed networks is a vital task in graph data mining and has been widely applied in many real-world scenarios. Despite the promising performance, existing contrastive learning-based anomaly detection models still suffer from a limitation: the lack of fine-grained contrastive tasks tailored for different anomaly types, which hinders their capability to capture diverse anomaly patterns effectively. To address this issue, we propose a novel multi-task contrastive learning framework that jointly optimizes two well-designed contrastive tasks: context matching and link prediction. The context matching task identifies contextual anomalies by measuring the congruence of the target node with its local context. The link prediction task fully exploits self-supervised information from the network structure and identifies structural anomalies by assessing the rationality of the local structure surrounding target nodes. By integrating these two complementary tasks, our framework can more precisely identify anomalies. Extensive experiments on four benchmark datasets demonstrate that our method achieves considerable improvement compared to state-of-the-art baselines.