#include <bits/stdc++.h>
using namespace std;
int a[10010], vis[110], kind[10010];
int main() {
  int t;
  cin >> t;
  while (t--) {
    int n, k;
    memset(vis, 0, sizeof(vis));
    cin >> n >> k;
    int num = 0;
    for (int i = 1; i <= n; i++) {
      cin >> a[i];
      if (vis[a[i]] == 0) vis[a[i]] = 1, kind[++num] = a[i];
    }
    if (num > k)
      cout << -1 << endl;
    else {
      for (int i = num + 1; i <= k; i++) kind[i] = kind[i - 1];
      for (int i = k + 1; i <= 9999; i++) kind[i] = kind[i - k];
      cout << 9999 << endl;
      for (int i = 1; i <= 9999; i++) cout << kind[i] << " ";
      cout << endl;
    }
  }
}
