#include <bits/stdc++.h>
#pragma GCC optimize("O3")
using namespace std;
const int N = 1e5 + 5;
int mx[N], p[N];
bool used[N];
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int t;
  cin >> t;
  while (t--) {
    int n;
    cin >> n;
    for (int i = 1; i <= n; ++i) cin >> mx[i], used[i] = false;
    p[1] = mx[1];
    used[p[1]] = true;
    int ind = 1;
    bool ok = true;
    for (int i = 2; i <= n; ++i) {
      while (used[ind]) ind++;
      if (!used[mx[i]]) {
        p[i] = mx[i];
        used[p[i]] = true;
        continue;
      }
      if (ind > mx[i]) {
        ok = false;
        break;
      }
      used[ind] = true;
      p[i] = ind++;
    }
    if (!ok) {
      cout << "-1\n";
      continue;
    }
    for (int i = 1; i <= n; ++i) cout << p[i] << " ";
    cout << "\n";
  }
}
