In a large nonstick skillet, heat the oil over medium-high. Add the onions and garlic and cook, stirring occasionally, until the vegetables start to soften, about 3 minutes. Add the mushrooms; cook, stirring often, until the mushrooms are tender and the onions start to brown, 5 to 6 minutes. Add the Swiss chard and cook, stirring occasionally, until tender, about 2 minutes. Season with salt and pepper and remove from the heat.
Arrange the tortillas on a work surface. Sprinkle half the cheese on the bottom half of each tortilla. Top each with the onion mixture, then the remaining cheese. Fold the tortillas in half; press lightly to flatten.
In a small saucepan, heat the beans with their liquid, the cumin and the hot sauce over medium, stirring often, until hot, 2 to 3 minutes; season with salt and cover.
Wipe out the skillet. Cook 2 quesadillas over medium until the cheese melts and the tortillas brown, 2 to 3 minutes per side. Repeat with the remaining quesadillas. Cut each quesadilla in half. Serve the beans on the side.