1 /* testreadonlyset.vala
3 * Copyright (C) 2008 Jürg Billeter
4 * Copyright (C) 2009 Didier Villevalois
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2.1 of the License, or (at your option) any later version.
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
21 * Tomaž Vajngerl <quikee@gmail.com>
22 * Julien Peeters <contact@julienpeeters.fr>
27 public class ReadOnlySetTests : ReadOnlyCollectionTests {
29 public ReadOnlySetTests () {
30 base.with_name ("ReadOnlySet");
33 public override void set_up () {
34 test_collection = new HashSet<string> ();
35 ro_collection = get_ro_view (test_collection);
38 public override void tear_down () {
39 test_collection = null;
43 protected override Collection<string> get_ro_view (Collection<string> collection) {
44 return ((Gee.Set) collection).read_only_view;