summaryrefslogtreecommitdiffhomepage
path: root/test
diff options
context:
space:
mode:
authorTom Black <[email protected]>2018-09-20 20:57:55 -0700
committerTom Black <[email protected]>2018-09-20 20:57:55 -0700
commit35a1c94eeef017413d0a20e68082441d2cd13264 (patch)
tree93603028741c922eefe3c36862b9a590db1d1d80 /test
parent5d386b3cf58dfeb1d9c02621814944c0e0648afc (diff)
downloadruby2d-35a1c94eeef017413d0a20e68082441d2cd13264.tar.gz
ruby2d-35a1c94eeef017413d0a20e68082441d2cd13264.zip
Expose window attributes through class methods
Diffstat (limited to 'test')
-rw-r--r--test/window_spec.rb12
1 files changed, 12 insertions, 0 deletions
diff --git a/test/window_spec.rb b/test/window_spec.rb
new file mode 100644
index 0000000..c49b824
--- /dev/null
+++ b/test/window_spec.rb
@@ -0,0 +1,12 @@
+require 'ruby2d'
+
+RSpec.describe Ruby2D::Window do
+
+ it 'returns class values' do
+ expect(Window.current).to be_a(Ruby2D::Window)
+ expect(Window.width).to eq(640)
+ set width: 200
+ expect(Window.width).to eq(200)
+ end
+
+end