#include <bits/stdc++.h>
using namespace std;
int main() {
  int t;
  cin >> t;
  while (t--) {
    int n;
    cin >> n;
    int a[n], b[n];
    for (int i = 0; i < n; i++) {
      cin >> a[i] >> b[i];
    }
    int p = 0, c = 0;
    int flag = 0;
    for (int i = 0; i < n; i++) {
      if (b[i] - c > a[i] - p || b[i] < c || a[i] < p) {
        flag = 1;
        break;
      }
      p = a[i];
      c = b[i];
    }
    if (flag == 0)
      cout << "Yes" << endl;
    else
      cout << "No" << endl;
  }
  return 0;
}
