Example #1
0
        public TeamsView()
        {
            InitializeComponent();
            this.WidthRequest = (Application.Current as App).Width;
            _vm = new TeamItemViewModel();

            IDownloadTeam download = new DownloadTeam();

            _vm.DownloadData(download, listView);
        }
Example #2
0
        public void TeamsViewIsUpdated()
        {
            //FixturesView ftView = new FixturesView();
            TeamItemViewModel teamsView = new TeamItemViewModel();

            MyListView lst = new MyListView();
            //lst = global::Xamarin.Forms.NameScopeExtensions.FindByName<global::PROJEKT.Views.Controls.MyListView>(ftView, "listView");

            DownloadTeams downresults = new DownloadTeams();

            teamsView.DownloadData(downresults, lst);


            List <CustomTeam> cstlst = (List <CustomTeam>)lst.ItemsSource;

            Assert.AreEqual(cstlst[0].Name, downresults.results.Teams[0].Name);
        }