#include <bits/stdc++.h>
using namespace std;
const int MAXN = 100100;
vector<pair<int, int> > calle;
vector<pair<int, int> >::iterator it;
int main() {
  ios::sync_with_stdio(0);
  cin.tie(nullptr);
  int T;
  cin >> T;
  for (int t = (0); t < (T); t++) {
    int n;
    long long a, b;
    cin >> n >> a >> b;
    char s[n];
    cin >> s;
    calle.clear();
    int current = s[0] - '0';
    int count = 1;
    bool allZero = 1;
    for (int i = (1); i < (n); i++) {
      if (current == (s[i] - '0'))
        count++;
      else {
        allZero = 0;
        calle.push_back({current, count});
        count = 1;
        current = s[i] - '0';
      }
    }
    if (allZero) {
      cout << a * n + b * (n + 1) << "\n";
      ;
      continue;
    }
    long long cost = 0;
    for (it = calle.begin() + 1; it != calle.end(); it++) {
      pair<int, int> v = *it;
      if (v.first)
        cost += b * (v.second + 1);
      else {
        if (v.second != 1) cost += min(2 * a, b * (v.second - 1));
      }
    }
    cost += a * (n + 2) + b * (n + 1);
    cout << cost << "\n";
  }
  return 0;
}
