#include <iostream>
#include <vector>
#include <algorithm>
using namespace std;

int main() {
	int testCase;
  cin >> testCase;
	while (testCase--) {
		vector<int> balls;
		int ball;
		cin >> ball;
		while (ball--) {
			int num;
			cin >> num;
			balls.push_back(num);
		}
		int maxNum = 1;
		int lastNum = balls[0];
		int count = 1;
		for (int i = 1;i < balls.size();i++) {
			if (balls[i] != lastNum) {
				lastNum = balls[i];
				maxNum = max(count, maxNum);
				count = 1;
			}
			else {
				count++;
			}
		}
		maxNum = max(count, maxNum);
		cout << maxNum << endl;
	}
	return 0;
}