#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  long long n, t;
  cin >> t;
  while (t--) {
    cin >> n;
    long long a[n], b[n];
    cin >> a[0] >> b[0];
    bool f = 1;
    if (n == 1) {
      if (a[0] >= b[0])
        cout << "YES\n";
      else
        cout << "NO\n";
      continue;
    }
    for (long long i = 1; i < n; i++) {
      cin >> a[i] >> b[i];
    }
    for (long long i = 1; i < n; i++) {
      if (a[0] < b[0]) {
        f = 0;
        break;
      }
      if (a[i] < a[i - 1]) {
        f = 0;
        break;
      }
      if (b[i] < b[i - 1]) {
        f = 0;
        break;
      }
      if (a[i] < b[i]) {
        f = 0;
        break;
      }
      if (a[i] - a[i - 1] < b[i] - b[i - 1]) {
        f = 0;
        break;
      }
    }
    if (!f)
      cout << "NO\n";
    else
      cout << "YES\n";
  }
  return 0;
}
