#include <bits/stdc++.h>
using namespace std;
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  long long int t;
  cin >> t;
  while (t--) {
    long long int n, a, b;
    cin >> n >> a >> b;
    vector<long long int> v(n);
    for (long long int i = 0; i < n; i++) {
      char c;
      cin >> c;
      if (c == '1')
        v[i] = 1LL;
      else
        v[i] = 0LL;
    }
    vector<long long int> ceros_unos;
    long long int d = 0LL;
    while (d < n) {
      long long int cont = 0LL;
      if (v[d] == 1LL) {
        while (d < n && v[d] == 1LL) {
          d++;
          cont++;
        }
      } else {
        while (d < n && v[d] == 0LL) {
          d++;
          cont++;
        }
      }
      ceros_unos.push_back(cont);
    }
    if (ceros_unos.size() == 1LL) {
      cout << b * (ceros_unos[0] + 1LL) + a * ceros_unos[0] << '\n';
      continue;
    }
    long long int primermasultimocero = 0LL;
    long long int l = ceros_unos[0];
    long long int r = ceros_unos.back();
    primermasultimocero = a * (l + r + 2LL) + b * (l + r);
    long long int unosentreceros = 0LL;
    for (long long int i = 1LL; i < ceros_unos.size(); i += 2LL) {
      unosentreceros += 2LL * b * (ceros_unos[i] + 1LL) + a * ceros_unos[i];
    }
    long long int cerosentreunos = 0LL;
    for (long long int i = 2LL; i < ceros_unos.size() - 1LL; i += 2LL) {
      long long int k = ceros_unos[i];
      long long int minimo;
      if ((b * (k - 1LL) + a * (k + 2LL)) < (b * (2LL * (k - 1LL)) + a * (k))) {
        minimo = b * (k - 1LL) + a * (k + 2LL);
      } else {
        minimo = b * (2LL * (k - 1LL)) + a * (k);
      }
      if (k == 1LL) minimo = a;
      cerosentreunos += minimo;
    }
    cout << primermasultimocero + unosentreceros + cerosentreunos << '\n';
  }
  return 0;
}
