$[\mathbb{T}^2,X]$ calculation: Request for Reference and check proof EDIT: I decided to add a corrected version of the proof for the sake of future visitors. The two answers below refer to the first version of the proof, not the second, corrected one.

I am trying to prove the following statement: If X is a simply-connected, path-connected Hausdorff topological space then $[\mathbb{T}^2,X]\cong\pi_2(X)$.
I would like to know:
A) Is the statement correct? If it is false, what kind of additional restrictions have to be put on $X$ to make it correct?
B) Is the following proof correct?
C) I am searching for references (hopefully all from the same textbook) for why step # 3 is true. So far I have checked Bredon and Hatcher but perhaps there is a better suited source? Since I am a novice perhaps I am just not connecting the dots correctly.

Proof (second, corrected version):
Writing $\mathbb{T}^2\cong\mathbb{S}^1\times\mathbb{S}^1$, we follow Mark Grant.
1) Since $\mathbb{T}^2$ is a CW-complex, it has a cell-structure, in which there is a 0-cell which is just a point, there is a figure-eight space $\mathbb{S}^1\vee\mathbb{S}^1$ where the two circles meet at the aforementioned point. $\mathbb{S}^1\vee\mathbb{S}^1$ is the 1-skeleton of $\mathbb{T}^2$, so that it is a one-dimensional sub-complex. This implies that the inclusion map $\mathbb{S}^1\vee\mathbb{S}^1\hookrightarrow\mathbb{T}^2$ is a cofibration (in the sense of [Bredon Def. VII.1.2]) by [B. Cor. VII.1.4].
2) Together with the attaching map $\mathbb{S}^1\to\mathbb{S}^1\vee\mathbb{S}^1$ we get the coexact sequence $$ \mathbb{S}^1\to\mathbb{S}^1\vee\mathbb{S}^1\to\mathbb{S}^1\times\mathbb{S}^1 $$ Suspension allows us to extend this sequence coexactly (via Bredon Cor VII.5.5) to get $$ \mathbb{S}^1\to\mathbb{S}^1\vee\mathbb{S}^1\to\mathbb{S}^1\times\mathbb{S}^1\to\mathbb{S}^2\to\mathbb{S}^2\vee\mathbb{S}^2\to\mathbb{S}^2\times\mathbb{S}^2\to\dots $$ where the first map is the attaching map and the fourth map is the suspension of the attaching map.
3) The suspension of the attachment map is nullhomotopic. Indeed, suspension induces a group morphism $\pi_1(\mathbb{S}^1\vee\mathbb{S}^1)\to\pi_2(\mathbb{S}^2\vee\mathbb{S}^2)$. Using the fact that $\pi_1(\mathbb{S}^1\vee\mathbb{S}^1)$ is the free group on two generators $\alpha,\beta$, the attaching map induces an element in $\pi_1(\mathbb{S}^1\vee\mathbb{S}^1)$ which may be written as $\alpha\beta\alpha^{-1}\beta^{-1}$. Now the group morphism property of the induced map $\pi_1(\mathbb{S}^1\vee\mathbb{S}^1)\to\pi_2(\mathbb{S}^2\vee\mathbb{S}^2)$ means and the fact that $\pi_n(Y)$ is Abelain for $n\geq2$ means $\alpha\beta\alpha^{-1}\beta^{-1}$ is sent to the identity element under this map. 
Using co-exactness, $\pi_1(X)=0$, and the fact that the suspension of the attaching map is nullhomotopic, we find the following exact sequence of pointed homotopy classes: $$\dots\to0\to\pi_2(X)\to[\mathbb{T}^2;X]\to[\mathbb{S}^1\vee\mathbb{S}^1;X]\to0$$ where we also replaced $[\mathbb{S}^2;X]\equiv\pi_2(X)$.
4) The wedge sum $\mathbb{S}^1\vee\mathbb{S}^1$ is a coproduct in the category of (homotopy) pointed top. spaces and so the functor $[-;X]$ respects it, and so we get the equality $[\mathbb{S}^1\vee\mathbb{S}^1;X]=[\mathbb{S}^1;X]\times[\mathbb{S}^1;X]\equiv\pi_1(X)^2$. But we assumed $\pi_1(X)=0$ so that finally we get the exact sequence $$\dots\to0\to\pi_2(X)\to[\mathbb{T}^2;X]\to0$$
5) Since $X$ is path-connected, we may replace $[-;X]$ (the set of pointed homotopy classes) with the set of homotopy classes.

Proof (first version):
Writing $\mathbb{T}^2\cong\mathbb{S}^1\times\mathbb{S}^1$, we follow the strategy of Mark Grant.
1) Since $\mathbb{T}^2$ is a CW-complex, it has a cell-structure, in which there is a 0-cell which is just a point, there is a figure-eight space $\mathbb{S}^1\vee\mathbb{S}^1$ where the two circles meet at the aforementioned point. $\mathbb{S}^1\vee\mathbb{S}^1$ is the 1-skeleton of $\mathbb{T}^2$, so that it is a one-dimensional sub-complex. This implies that the inclusion map $\mathbb{S}^1\vee\mathbb{S}^1\hookrightarrow\mathbb{T}^2$ is a cofibration (in the sense of [Bredon Def. VII.1.2]) by [B. Cor. VII.1.4].
2) Since $\mathbb{S}^2\cong\mathbb{T}^2/(\mathbb{S}^1\vee\mathbb{S}^1)$ we can also use [B. Cor. VII.5.5] to deduce that since $\mathbb{S}^1\vee\mathbb{S}^1$ is closed in $\mathbb{T}^2$, the sequence $$ \mathbb{S}^1\vee\mathbb{S}^1 \to \mathbb{T}^2\to\mathbb{S}^2\to S(\mathbb{S}^1\vee\mathbb{S}^1)\to \dots$$ is co-exact, where the first map is the attachment map of the CW-complex, and the last map is a suspension of the attachment map. Being co-exact means that the sequence of pointed homotopy classes $$\dots\to[S(\mathbb{S}^1\vee\mathbb{S}^1);X]\to[\mathbb{S}^2;X]\to[\mathbb{T}^2;X]\to[\mathbb{S}^1\vee\mathbb{S}^1;X]$$ is exact.
3) The suspension of the attachment map is nullhomotopic, so that we get the exact sequence $$\dots\to0\to\pi_2(X)\to[\mathbb{T}^2;X]\to[\mathbb{S}^1\vee\mathbb{S}^1;X]$$ where we replaced $[\mathbb{S}^2;X]\equiv\pi_2(X)$.
4) The wedge sum $\mathbb{S}^1\vee\mathbb{S}^1$ is a coproduct in the category of (homotopy) pointed top. spaces and so the functor $[-;X]$ respects it, and so we get the equality $[\mathbb{S}^1\vee\mathbb{S}^1;X]=[\mathbb{S}^1;X]\times[\mathbb{S}^1;X]\equiv\pi_1(X)^2$. But we assumed $\pi_1(X)=0$ so that finally we get the exact sequence $$\dots\to0\to\pi_2(X)\to[\mathbb{T}^2;X]\to0$$
5) Since $X$ is path-connected, we may replace $[-;X]$ (the set of pointed homotopy classes) with the set of homotopy classes.
 A: The good news is the statement is correct! But I believe there is a flaw in your proof in step 3.  Specifically I believe the map $\mathbb{S}^2\to S(\mathbb{S}^1\wedge\mathbb{S}^1)$ is not null-homotopic.  I'm not positive about Bredon, but Hatcher constructs this sequence in the following manner:
$$
\mathbb{S}^1\wedge\mathbb{S}^1 \to \mathbb{T}^2 \to \mathbb{T}^2\cup C(\mathbb{S}^1\wedge\mathbb{S}^1) \to C\mathbb{T}^2\cup C(\mathbb{S}^1\wedge\mathbb{S}^1)
$$
Where the $C$'s represent taking the cone over a space and all maps are the inclusions.  We arrive at the sequence you have above via homotopy equivalences between the corresponding third and fourth terms of our sequences.  Now, if indeed this map were null-homotopic then we would have the following homotopy equivalence:
$$
C\mathbb{T}^2\cup C(\mathbb{S}^1\wedge\mathbb{S}^1)\cong C\mathbb{T}^2\cup C(\mathbb{S}^1\wedge\mathbb{S}^1) / (\mathbb{T}^2\cup C(\mathbb{S}^1\wedge\mathbb{S}^1)) \cong C\mathbb{T}^2/\mathbb{T}^2 =S\mathbb{T}^2
$$ 
Where the first equivalence follows from the assumed fact that $\mathbb{T}^2\cup C(\mathbb{S}^1\wedge\mathbb{S}^1)$ is a contractible subspace of $C\mathbb{T}^2\cup C(\mathbb{S}^1\wedge\mathbb{S}^1)$.  On the other hand, we have that:
$$
C\mathbb{T}^2\cup C(\mathbb{S}^1\wedge\mathbb{S}^1) \cong C\mathbb{T}^2\cup C(\mathbb{S}^1\wedge\mathbb{S}^1) / C\mathbb{T}^2 \cong S(\mathbb{S}^1\wedge\mathbb{S}^1)
$$
Now it is not too hard to see that $S(\mathbb{S}^1\wedge\mathbb{S}^1)$ is not homotopy equivalent to $S\mathbb{T}^2$ since $H_3(S\mathbb{T}^2)=H_2(\mathbb{T}^2)=\mathbb{Z}$ while $H_3(S(\mathbb{S}^1\wedge\mathbb{S}^1)) = H_2(\mathbb{S}^1\wedge\mathbb{S}^1)=0$.  Thus we have a contradiction and this map is not nullhomotopic.  
Now, the statement is actually true. To see this, we can make use of Proposition 4.13 from Hatcher which states that $X$ is weak homotopy equivalent to a CW complex $Z$ which, by the construction in Hatcher, has no $1$ cells because we assumed that $X$ is simply connected.  Since $X$ and $Z$ are weak homotopy equivalent we have a bijection $[\mathbb{T}^2,X] \longleftrightarrow [\mathbb{T}^2,Z]$.  Now, if $f:\mathbb{T}^2\to Z$ is any continuous map, we know that $f$ is homotopic to a cellular map $g:\mathbb{T}^2\to Z$.  Since the 1-skeleton of $Z$ is a single point, $g$ will factor through a function $f':\mathbb{S}^2\to Z$.  I claim that the map $[f]\to [f']$ gives the bijection we are looking for.  The inverse is given by $[f']\to [f'\circ q]$ where $q:\mathbb{T}^2\to \mathbb{S}^2$ is the quotient by the one skeleton. 
For the case where $X$ is not simply connected there is a really good description here.
A: To answer first your questions. A) The statement is correct, and B) your proof is correct, including step $3)$.
I'm not sure of a good reference (I'd guess Hatcher has a thing to say about it, though), but a way to see what the attaching map is is as follows.
We know that $S^1\times S^1$ is a CW complex consisting of two 1-cells and a single 2-cell. Thus we have a cofibration sequence
$$S^1\xrightarrow{w}S^1\vee S^1\rightarrow S^1\times S^1$$
where $w$ is the attaching map and represents a class in $\pi_1(S^1\vee S^1)$. Using the Seifert-Van Kampen theorem we find that $\pi_1(S^1\vee S^1)\cong \mathbb{Z}\ast\mathbb{Z}$ is the free group on the two generators, $a=in_1:S^1\hookrightarrow S^1\vee S^1$, $b=in_2:S^1\hookrightarrow S^1\vee S^1$ given by the inclusions of the two respective wedge summands. Thus the homotopy class $w=a^{i_1}b^{j_1}\dots a^{i_r}b^{j_r}$ is some word in the generators $a,b$.
Now the abelianisation of this is just the free abelian group on these two generators $(\pi_1(S^1\vee S^1))_{ab}\cong\mathbb{Z}\oplus\mathbb{Z}$, and the Hurewicz theorem tells you that this is isomorphic to the homology $H_1(S^1\vee S^1)$. Now $H_1(S^1\times S^1)\cong\mathbb{Z}\oplus\mathbb{Z}$ also, and the inclusion of the 1-skeleton $S^1\vee S^1\hookrightarrow S^1\times S^1$ induces an isomorphism on homology. We see this using the homology exact sequence of the cofibration above
$$0\rightarrow H_2(S^1\times S^1)\xrightarrow{\cong} H_1(S^1)\xrightarrow{w_*} H_1(S^1\vee S^1)\xrightarrow{\cong} H_1(S^1\times S^1)\rightarrow 0.$$
The right hand map must be an isomorphism since both involved groups are free abelian and there is no torsion in the sequence. It follows that the left-hand map is also an isomorphism, since $H_2(S^1\times S^1)\cong\mathbb{Z}$ and $H_1(S^1)\cong\mathbb{Z}$ (they are oriented manifolds 2- and 1-manifolds respectively). Thus $w_*=0$ on homology.
The point of introducing the Hurewicz theorem earlier was that we may use its naturality to get a commutative diagram
$\require{AMScd}$
\begin{CD}
    @>>>0@>>>\pi_1S^1@>\pi(w)>>\pi_1(S^1\vee S^1)@>>>\pi_1(S^1\times S^1)@>>>0\\
    @V  V V @VV  V@VV \cong V @V V(-)_{ab}V@VV\cong V\\
 0@>>>  H_2(S^1\times S^1)@>>>H_1S^1@>w_*>>H_1(S^1\vee S^1)@>\cong>> H_1(S^1\times S^1)@>>>0
\end{CD}
Here the vertical maps are all Hurewicz morphisms. All three are abelianisations, and two turn out to be isomorphisms, using that $\pi_1(S^1\times S^1)=\pi_1S^1\oplus\pi_1S^1\cong\mathbb{Z}\oplus\mathbb{Z}$. $\pi(w)$ is the homomorphism induced by $w$. The bottom row of this diagram is exact, although the top is not necessarily so.
Since $\pi_1S^1$ is free abelian the homomorphism $\pi(w)$ will be determined by what it does on the generator, which is the identity $id_{S^1}$. Note that
$$\pi(w)[id_{S^1}]=[w\circ id_{S^1}]=[w].$$
Now we observed above that $w_*=0$, so the commutative diagram above tells us that $(\pi(w))_{ab}=0$. Thus $w$ lies in the kernel of the abelianisation homomorphism $ab:\mathbb{Z}\ast\mathbb{Z}\rightarrow \mathbb{Z}\oplus\mathbb{Z}$, which sends the free generators $a,b$ to the free abelian generators of the same name. The kernel of this map is the subgroup generated by commutators $[x,y]=xyx^{-1}y^{-1}$ in the words.
The point is that while $w$ is non-trivial in the non-abelian group $\pi_1(S^1\vee S^1)$, after suspending it becomes trivial in the abelian group $\pi_2(\Sigma (S^1\vee S^1))$ (recall that $\pi_2$ is always abelian). 
In fact if $X$ is a path connected space then the Hurewicz map $h_1:\pi_1(X)\rightarrow H_1X$ is an abelianisation. However, after suspension $\pi_1\Sigma X=0$ so the Hurewicz map $h_2:\pi_2X\xrightarrow{\cong} H_1X$ is now an isomorphism. The suspension homomorphism $\Sigma:\pi_1X\rightarrow\pi_2\Sigma X$ actually identifies with the abelianisation, and this follows from naturality $h_2\circ \Sigma=\sigma\circ h_1$, where $h_2$ is the isomorphism above, $\sigma:H_1X\xrightarrow{\cong} H_2\Sigma X$ is the homology suspension, which is also an isomorphism, and $h_1$ is abelianisation.
Hence $\Sigma w=0\in\pi_2(\Sigma(S^1\vee S^1))=\pi_2(S^2\vee S^2)\cong\mathbb{Z}\oplus\mathbb{Z}$.
Incidentally, the map $w$ is a so-called Whitehead product, and takes the form 
$$w=aba^{-1}b^{-1}.$$ 
You can see it has this form explicitly by identifying the torus $S^1\times S^1$ as a quotient of $I\times I$. The identification traces around the oriented boundaries, as indicated in Hatcher pg. 5. 
More explicitly, Hatcher describes the product cell structure on a product of CW complexes on pg. 8. Then the cell structure on $S^1$ with one $0$-cell and one $1$-cell is given by identifying the two points in the boundary $S^0\cong \partial I$. Choosing a relative homeomorphism $(D^2,S^1)\cong (I\times I,I\times\partial I\cup \partial I\times I)$ and keeping track of the orientations it is clear that $w$ indeed has the form described.
The Whitehead product has higher dimensional generalisations that give attaching maps for the top cells of all products $S^n\times S^m$, and indeed more generally for any product of the form $\Sigma X\times \Sigma Y$.
