This paper investigates the effect of surface roughness on fluid viscosity using molecular dynamics simulations. The three-dimensional model consists of liquid argon flowing between two solid walls whose surface roughness was modeled using fractal theory. In tandem with previously published experimental work, our results show that, while the viscosity in smooth channels remains constant across the channel width, in the presence of surface roughness it increases close to the walls. The increase of the boundary viscosity is further accentuated by an increase in the depth of surface roughness. We attribute this behavior to the increased momentum transfer at the boundary, a result of the irregular distribution of fluid particles near rough surfaces. Furthermore, although the viscosity in smooth channels has previously been shown to be independent of the strength of the solid-liquid interaction, here we show that in the presence of surface roughness, the boundary viscosity increases with the solid's wettability. The paper concludes with an analytical description of the viscosity as a function of the distance from the channel walls, the walls' surface roughness, and the solid's wetting properties. The relation can potentially be used to adjust the fluid dynamics equations for a more accurate description of microfluidic systems.