#include <bits/stdc++.h>
using namespace std;
void solve() {
  int n;
  cin >> n;
  vector<pair<int, int> > a(n, make_pair(0, 0));
  for (int i = 0; i < n; i++) {
    int x, b;
    cin >> x >> b;
    a[i] = make_pair(x, b);
  }
  if (a[0].first < a[0].second) {
    cout << "NO" << endl;
    return;
  }
  for (int i = 1; i < n; i++) {
    if (a[i].first == a[i - 1].first && a[i].second == a[i - 1].second &&
        a[i].first >= a[i].second)
      continue;
    else if (a[i].first > a[i - 1].first && a[i].second >= a[i - 1].second &&
             (a[i].second - a[i - 1].second) <= (a[i].first - a[i - 1].first) &&
             a[i].first >= a[i].second)
      continue;
    else {
      cout << "NO" << endl;
      return;
    }
  }
  cout << "YES" << endl;
  return;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  int t;
  cin >> t;
  while (t--) solve();
  return 0;
}
