#include <bits/stdc++.h>
using namespace std;
const bool DBG = 1;
using ll = long long;
using vi = vector<int>;
using vvi = vector<vi>;
using vll = vector<ll>;
using vvll = vector<vll>;
using vb = vector<bool>;
using vd = vector<double>;
using vs = vector<string>;
using pii = pair<int, int>;
using pll = pair<ll, ll>;
using pdd = pair<double, double>;
using vpii = vector<pii>;
using vvpii = vector<vpii>;
using vpll = vector<pll>;
using vvpll = vector<vpll>;
using vpdd = vector<pdd>;
using vvpdd = vector<vpdd>;
template <typename T>
void ckmin(T& a, const T& b) {
  a = min(a, b);
}
template <typename T>
void ckmax(T& a, const T& b) {
  a = max(a, b);
}
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  cout << fixed << setprecision(15);
  int T;
  cin >> T;
  for (int t = (0); t < (T); t++) {
    int n;
    cin >> n;
    int a, l;
    cin >> l;
    int e = -1;
    for (int i = (1); i < (n); i++) {
      cin >> a;
      if (abs(a - l) > 1) {
        e = i;
      }
      l = a;
    }
    if (e >= 0) {
      cout << "YES" << endl << e << " " << e + 1 << endl;
    } else {
      cout << "NO" << endl;
    }
  }
  return 0;
}
