package com.lemon.testng;

import org.testng.annotations.DataProvider;
import org.testng.annotations.Test;

/**
 * @program: Lemon
 * @description:
 * @author: ray
 * @create: 2022-09-22 16:45
 **/
public class TestNGDataProvider {

    @Test(dataProvider = "datas")
    public void testLogin(String username, String password) {
        System.out.println(username + ":" + password);
    }

    @DataProvider(name = "datas")
    public Object[][] datas() {
//        Object[][] datas = new Object[1][2];
        Object[][] datas = {
                {"zhangsan", "123"},
                {"wangsans", "456"},
                {"zhangpin", "789"},
        };
        return datas;
    }

}


