#include <bits/stdc++.h>
using namespace std;
const int N = 2e5;
const long long INF = 1e17;
long long t, n, a, b;
long long dp[N + 5][2];
string s;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  cin >> t;
  while (t--) {
    cin >> n >> a >> b >> s;
    dp[0][0] = b;
    dp[0][1] = INF;
    for (int i = 1; i <= n; i++) {
      if (s[i - 1] == '1') {
        dp[i][0] = INF;
        dp[i][1] = dp[i - 1][1] + a + 2 * b;
      } else if (i - 2 >= 0 && s[i - 2] == '1') {
        dp[i][0] = dp[i - 1][1] + 2 * a + b;
        dp[i][1] = dp[i - 1][1] + a + 2 * b;
      } else {
        dp[i][0] = min(dp[i - 1][0] + a, dp[i - 1][1] + 2 * a) + b;
        dp[i][1] = min(dp[i - 1][0] + 2 * a, dp[i - 1][1] + a) + 2 * b;
      }
    }
    cout << dp[n][0] << '\n';
  }
  return 0;
}
