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