public void SetTest() { this.scrollRectSnap = Substitute.For <IScrollRectSnap>(); this.btn = Substitute.For <IScrollButton>(); this.btn.Init(scrollRectSnap); this.btn.ScrollRectSnapInstance.MinSize.Returns(0.5f); this.container = new ScrollButtonContainer(this.btn); }
public void Init(IScrollRectSnap scrollRectSnap) { this.rt = this.gameObject.GetComponent <RectTransform>(); this.scrollBtn = new ScrollButtonContainer(this as IScrollButton); this.scrollRectSnap = scrollRectSnap; }