# Simulation Datasets
data1 <- toyModel("ICA_Type1", seeds=1)
data2 <- toyModel("ICA_Type2", seeds=2)
data3 <- toyModel("ICA_Type3", seeds=3)
data4 <- toyModel("ICA_Type4", seeds=4)
data5 <- toyModel("ICA_Type5", seeds=5)
data6 <- toyModel("MICA", seeds=6)
data7 <- toyModel("GroupICA", seeds=7)

set.seed(1)
data1_ <- iTensor:::.ICA_Type1()
set.seed(2)
data2_ <- iTensor:::.ICA_Type2()
set.seed(3)
data3_ <- iTensor:::.ICA_Type3()
set.seed(4)
data4_ <- iTensor:::.ICA_Type4()
set.seed(5)
data5_ <- iTensor:::.ICA_Type5()
set.seed(6)
data6_ <- iTensor:::.MICA()
set.seed(7)
data7_ <- iTensor:::.GroupICA()

expect_true(length(data1) == 3)
expect_true(all(lapply(data1, nrow) == c(500,500,3)))
expect_true(all(lapply(data1, ncol) == 3))
expect_identical(data1, data1_)

expect_true(length(data2) == 3)
expect_true(all(lapply(data2, nrow) == c(500,500,3)))
expect_true(all(lapply(data2, ncol) == 3))
expect_identical(data2, data2_)

expect_true(length(data3) == 3)
expect_true(all(lapply(data3, nrow) == c(500,500,3)))
expect_true(all(lapply(data3, ncol) == 3))
expect_identical(data3, data3_)

expect_true(length(data4) == 3)
expect_true(all(lapply(data4, nrow) == c(480,480,3)))
expect_true(all(lapply(data4, ncol) == 3))
expect_identical(data4, data4_)

expect_true(length(data5) == 4)
expect_true(all(lapply(data5, nrow) == c(64,64,64,3116)))
expect_true(all(lapply(data5, ncol) == c(3116,10,4,2)))
expect_identical(data5, data5_)

expect_true(length(data6) == 2)
expect_true(all(lapply(data6, nrow) == 10001))
expect_true(all(lapply(data6, ncol) == 3))
expect_identical(data6, data6_)

expect_true(length(data7) == 2)
expect_true(all(lapply(data7, nrow) == 5000))
expect_true(all(lapply(data7, ncol) == 6))
expect_identical(data7, data7_)
